skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • NEW: Design Kits for Figma
    • Online Training
    • Document Processing Library
    • Embedded Reporting for web and desktop

    Web

    Kendo UI UI for Angular UI for Vue UI for jQuery KendoReact UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Telerik JustMock

    CMS

    Sitefinity

    AI Productivity Tools

    AI Coding Assistants

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    KendoReact Free VB.NET to C# Converter Testing Framework
    View all products
  • Overview
    • What's New
    • Roadmap
    • Release History
  • Docs & Support
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class CollectionExpectation<TReturn>

Defines expectation for a System.Linq.IQueryable collection.

Inheritance
System.Object
CommonExpectation<FuncExpectation<TReturn>>
CollectionExpectation<TReturn>
FuncExpectation<TReturn>
Inherited Members
CommonExpectation<FuncExpectation<TReturn>>.ProcessDoInstead(Delegate, Boolean)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead(Action)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead(Delegate)
CommonExpectation<FuncExpectation<TReturn>>.Raises(Action, Object[])
CommonExpectation<FuncExpectation<TReturn>>.Raises(Action, EventArgs)
CommonExpectation<FuncExpectation<TReturn>>.Raises<T1>(Action, Func<T1, EventArgs>)
CommonExpectation<FuncExpectation<TReturn>>.Raises<T1, T2>(Action, Func<T1, T2, EventArgs>)
CommonExpectation<FuncExpectation<TReturn>>.Raises<T1, T2, T3>(Action, Func<T1, T2, T3, EventArgs>)
CommonExpectation<FuncExpectation<TReturn>>.Raises<T1, T2, T3, T4>(Action, Func<T1, T2, T3, T4, EventArgs>)
CommonExpectation<FuncExpectation<TReturn>>.Throws(Exception)
CommonExpectation<FuncExpectation<TReturn>>.Throws<T>()
CommonExpectation<FuncExpectation<TReturn>>.Throws<T>(Object[])
CommonExpectation<FuncExpectation<TReturn>>.ThrowsAsync(Exception)
CommonExpectation<FuncExpectation<TReturn>>.ThrowsAsync<T>()
CommonExpectation<FuncExpectation<TReturn>>.ThrowsAsync<T>(Object[])
CommonExpectation<FuncExpectation<TReturn>>.CallOriginal()
CommonExpectation<FuncExpectation<TReturn>>.DoNothing()
CommonExpectation<FuncExpectation<TReturn>>.MustBeCalled(String)
CommonExpectation<FuncExpectation<TReturn>>.Occurs(Int32, String)
CommonExpectation<FuncExpectation<TReturn>>.OccursAtLeast(Int32, String)
CommonExpectation<FuncExpectation<TReturn>>.OccursAtMost(Int32, String)
CommonExpectation<FuncExpectation<TReturn>>.OccursOnce(String)
CommonExpectation<FuncExpectation<TReturn>>.OccursNever(String)
CommonExpectation<FuncExpectation<TReturn>>.InSequence()
CommonExpectation<FuncExpectation<TReturn>>.InOrder(String)
CommonExpectation<FuncExpectation<TReturn>>.AfterAll(IPrerequisite[])
CommonExpectation<FuncExpectation<TReturn>>.IgnoreInstance()
CommonExpectation<FuncExpectation<TReturn>>.OnAllThreads()
CommonExpectation<FuncExpectation<TReturn>>.When(Func<Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.IgnoreArguments()
CommonExpectation<FuncExpectation<TReturn>>.Dispose()
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1>(Action<T1>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2>(Action<T1, T2>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3>(Action<T1, T2, T3>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4>(Action<T1, T2, T3, T4>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5>(Action<T1, T2, T3, T4, T5>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6>(Action<T1, T2, T3, T4, T5, T6>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7>(Action<T1, T2, T3, T4, T5, T6, T7>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8>(Action<T1, T2, T3, T4, T5, T6, T7, T8>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>)
CommonExpectation<FuncExpectation<TReturn>>.DoInstead<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(Action<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1>(Func<T1, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2>(Func<T1, T2, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3>(Func<T1, T2, T3, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4>(Func<T1, T2, T3, T4, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5>(Func<T1, T2, T3, T4, T5, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6>(Func<T1, T2, T3, T4, T5, T6, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7>(Func<T1, T2, T3, T4, T5, T6, T7, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8>(Func<T1, T2, T3, T4, T5, T6, T7, T8, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.When<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16>(Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, Boolean>)
CommonExpectation<FuncExpectation<TReturn>>.IsMet
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Telerik.JustMock.Expectations
Assembly: Telerik.JustMock.dll

Syntax

public class CollectionExpectation<TReturn> : CommonExpectation<FuncExpectation<TReturn>>, IAction<FuncExpectation<TReturn>>, IDoInstead<FuncExpectation<TReturn>>, IThrows<FuncExpectation<TReturn>>, IAssertable, IMustBeCalled, ISetupBehavior, IOccurrence, IOrder, IPrerequisite, IDisposable, IInstanceScope<FuncExpectation<TReturn>>, IMethodMock, IReturnCollection
Type Parameters
TReturn

Methods

ProcessReturnsValue(TReturn)

Implementation detail.

Declaration
protected void ProcessReturnsValue(TReturn value)
Parameters
TReturn value

ReturnsCollection<TArg>(IEnumerable<TArg>)

Returns a enumerable collection for the target query.

Declaration
public IAssertable ReturnsCollection<TArg>(IEnumerable<TArg> collection)
Parameters
System.Collections.Generic.IEnumerable<TArg> collection

Enumerable collection

Returns
IAssertable

Instance of IAssertable

Type Parameters
TArg

Argument type

Implements
IReturnCollection.ReturnsCollection<TArg>(IEnumerable<TArg>)

Extension Methods

FluentHelper.Arrange<T, TResult>(T, Expression<Func<T, TResult>>)
FluentHelper.Arrange<T>(T, Expression<Action<T>>)
FluentHelper.ArrangeSet<T>(T, Action<T>)
FluentHelper.ArrangeLike<T>(T, Expression<Func<T, Boolean>>)
FluentHelper.Assert<T, TReturn>(T, Expression<Func<T, TReturn>>, String)
FluentHelper.Assert<T, TReturn>(T, Expression<Func<T, TReturn>>, Occurs, String)
FluentHelper.Assert<T>(T, Expression<Action<T>>, String)
FluentHelper.Assert<T>(T, Expression<Action<T>>, Occurs, String)
FluentHelper.AssertSet<T>(T, Action<T>, String)
FluentHelper.AssertSet<T>(T, Action<T>, Occurs, String)
FluentHelper.Raise<T>(T, Action<T>, EventArgs)
FluentHelper.Raise<T>(T, Action<T>, Object[])
FluentHelper.Assert<T>(T, String)
FluentHelper.AssertAll<T>(T, String)
MultipleReturnValueChainHelper.Returns<TReturn>(IAssertable, TReturn)
Getting Started
  • Unit Testing and Mocking Explained
  • Videos
  • FAQs
Community
  • Forums
  • Blogs
  • Feedback Portal

Copyright © 2019 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.