Class StoryList
Represents a list of Story objects.
Inherited Members
Namespace: IRM.Domain.Tests
Assembly: IRM.dll
Syntax
public class StoryList : ICollection<Story>, IEnumerable<Story>, IEnumerable
Properties
Count
Gets the number of stories in the StoryList.
Declaration
public int Count { get; }
Property Value
System.Int32
The number of stories in the StoryList. |
Implements
IsReadOnly
Gets a value indicating whether the StoryList is read-only.
Declaration
public bool IsReadOnly { get; }
Property Value
Boolean
true if the StoryList is read-only; otherwise, false. |
Implements
Item[String]
Gets the Story with the specified title.
Declaration
public Story this[string title] { get; }
Parameters
String
title
The title of the Story to get. |
Property Value
Story
The Story with the specified title or null if it does not exists. |
Methods
Add(Type)
Adds a story based on the specified test class.
Declaration
public Story Add(Type testClass)
Parameters
System.Type
testClass
The System.Type representing a test class. |
Returns
Story
The added Story. |
Add(Type, ScenarioTestAttribute)
Adds a story based on the specified test class.
Declaration
public Story Add(Type testClass, ScenarioTestAttribute attribute)
Parameters
System.Type
testClass
The System.Type representing a test class. |
ScenarioTestAttribute
attribute
The ScenarioTestAttribute that is applied to the test class. |
Returns
Story
The added Story. |
Clear()
ComplementStoriesFromDocumentation(IEnumerable<BaseDocumentationInfo>)
Complements narrative, given and when from documentation.
Declaration
public StoryList ComplementStoriesFromDocumentation(IEnumerable<BaseDocumentationInfo> documentation)
Parameters
IEnumerable<BaseDocumentationInfo>
documentation
The parsed documentation information. |
Returns
StoryList
|
Contains(Story)
Declaration
public bool Contains(Story story)
Parameters
Story story |
Returns
Boolean
true if |
Implements
CopyTo(Story[], Int32)
Copies the stories of the StoryList to an System.Array, starting at a particular System.Array index.
Declaration
public void CopyTo(Story[] array, int arrayIndex)
Parameters
Story[]
array
The one-dimensional System.Array that is the destination of the elements copied from StoryList. The System.Array must have zero-based indexing. |
System.Int32
arrayIndex
The zero-based index in |
Implements
FromAssembly(IEnumerable<Assembly>)
Creates a StoryList with all stories that exists in the System.Reflection.Assembly.
Declaration
public static StoryList FromAssembly(IEnumerable<Assembly> assemblies)
Parameters
IEnumerable<System.Reflection.Assembly>
assemblies
A collection of System.Reflection.Assembly to search for all stories. |
Returns
StoryList
A StoryList with all stories that exists in the System.Reflection.Assembly. |
Remarks
All types decorated with the ScenarioTestAttribute will be used to create stories.
FromAssembly(Assembly)
Creates a StoryList with all stories that exists in the System.Reflection.Assembly.
Declaration
public static StoryList FromAssembly(Assembly assembly)
Parameters
System.Reflection.Assembly
assembly
The System.Reflection.Assembly to search for all stories. |
Returns
StoryList
A StoryList with all stories that exists in the System.Reflection.Assembly. |
Remarks
All types decorated with the ScenarioTestAttribute will be used to create stories.
FromAssembly(String)
Creates a StoryList with all stories that exists in the System.Reflection.Assembly that will be loaded from the specified path.
Declaration
public static StoryList FromAssembly(string path)
Parameters
String
path
The name or path of the file, or directory, that contains the manifest of the assembly. |
Returns
StoryList
A StoryList with all stories that exists in the System.Reflection.Assembly. |
Remarks
All types decorated with the ScenarioTestAttribute will be used to create stories.
GetEnumerator()
Gets an enumerator that iterates through the StoryList.
Declaration
public IEnumerator<Story> GetEnumerator()
Returns
System.Collections.Generic.IEnumerator<Story>
Returns an enumerator that iterates through the StoryList. |
Implements
Remove(Story)
Declaration
public bool Remove(Story story)
Parameters
Story story |
Returns
Boolean
|
Implements
Explicit Interface Implementations
ICollection<Story>.Add(Story)
Declaration
void ICollection<Story>.Add(Story item)
Parameters
Story
item
|
Implements
IEnumerable.GetEnumerator()
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
System.Collections.IEnumerator
|