diff --git a/09-NoSQL/Assemblies/GrEmit.XML b/09-NoSQL/Assemblies/GrEmit.XML
new file mode 100644
index 0000000..de15062
--- /dev/null
+++ b/09-NoSQL/Assemblies/GrEmit.XML
@@ -0,0 +1,816 @@
+
+
+
+ GrEmit
+
+
+
+
+ Declares a local variable of the specified type, optionally pinning the object referred to by the variable.
+
+ A Type object that represents the type of the local variable.
+ Name of the local being declared.
+ true to pin the object in memory; otherwise, false.
+ A Local object that represents the local variable.
+
+
+
+ Declares a local variable of the specified type, optionally pinning the object referred to by the variable.
+
+ A Type object that represents the type of the local variable.
+ true to pin the object in memory; otherwise, false.
+ A Local object that represents the local variable.
+
+
+
+ Declares a new label.
+
+ Name of label.
+ A Label object that can be used as a token for branching.
+
+
+
+ Marks the Common intermediate language (CIL) stream's current position with the given label.
+
+ The Label object to mark the CIL stream's current position with.
+
+
+
+ Emits the Common intermediate language (CIL) to call System.Console.WriteLine with a string.
+
+ The string to be printed.
+
+
+
+ Marks a sequence point in the Common intermediate language (CIL) stream.
+
+ The document for which the sequence point is being defined.
+ The line where the sequence point begins.
+ The column in the line where the sequence point begins.
+ The line where the sequence point ends.
+ The column in the line where the sequence point ends.
+
+
+
+ Begins an exception block for a non-filtered exception.
+
+ The Label object for the end of the block. This will leave you in the correct place to execute finally blocks or to finish the try.
+
+
+
+ Begins a catch block.
+
+ The Type object that represents the exception.
+
+
+
+ Begins an exception block for a filtered exception.
+
+
+
+
+ Begins an exception fault block in the Common intermediate language (CIL) stream.
+
+
+
+
+ Begins a finally block in the Common intermediate language (CIL) instruction stream.
+
+
+
+
+ Ends an exception block.
+
+
+
+
+ Fills space if opcodes are patched. No meaningful operation is performed although a processing cycle can be consumed.
+
+
+
+
+ Throws the exception object currently on the evaluation stack.
+
+
+
+
+ Implements a jump table.
+
+ The array of Label object to jump to.
+
+
+
+ Returns from the current method, pushing a return value (if present) from the callee's evaluation stack onto the caller's evaluation stack.
+
+
+
+
+ Exits a protected region of code, unconditionally transferring control to a specific target instruction.
+
+ The Label object to jump to.
+
+
+
+ Unconditionally transfers control to a target instruction.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if value is false, a null reference, or zero.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if value is true, not null, or non-zero.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if the first value is less than or equal to the second value.
+
+
+ A Type object representing the type of values being compared.
+
+ Depending on whether the is signed or unsigned either Ble or Ble_Un instruction will be emitted.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if the first value is greater than or equal to the second value.
+
+
+ A Type object representing the type of values being compared.
+
+ Depending on whether the is signed or unsigned either Bge or Bge_Un instruction will be emitted.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if the first value is less than the second value.
+
+
+ A Type object representing the type of values being compared.
+
+ Depending on whether the is signed or unsigned either Blt or Blt_Un instruction will be emitted.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if the first value is greater than the second value.
+
+
+ A Type object representing the type of values being compared.
+
+ Depending on whether the is signed or unsigned either Bgt or Bgt_Un instruction will be emitted.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction when two unsigned integer values or unordered float values are not equal.
+
+ The Label object to jump to.
+
+
+
+ Transfers control to a target instruction if two values are equal.
+
+ The Label object to jump to.
+
+
+
+ Removes the value currently on top of the evaluation stack.
+
+
+
+
+ Copies the current topmost value on the evaluation stack, and then pushes the copy onto the evaluation stack.
+
+
+
+
+ Loads the address of the local variable at a specific index onto the evaluation stack.
+
+ The Local object whose address needs to be loaded onto the evaluation stack.
+
+
+
+ Loads the local variable at a specific index onto the evaluation stack.
+
+ The Local object which needs to be loaded onto the evaluation stack.
+
+
+
+ Pops the current value from the top of the evaluation stack and stores it in a the local variable list at a specified index.
+
+ The Local object in which the value must be stored.
+
+
+
+ Pushes a null reference (type O) onto the evaluation stack.
+
+
+ The Type of object being pushed onto the evaluation stack.
+
+ Needed only for increasing readability of the IL code being generated.
+
+
+
+
+ Initializes each field of the value type at a specified address to a null reference or a 0 of the appropriate primitive type.
+
+ The Type of object being initialized. Must be a value type.
+
+
+
+ Loads an argument (referenced by a specified index value) onto the evaluation stack.
+
+
+ Index of the argument being pushed.
+
+ Depending on that index emits on of the following instructions:
+
+ Ldarg_0, Ldarg_1, Ldarg_2,
+ Ldarg_3, Ldarg_S, Ldarg
+
+
+
+
+ Stores the value on top of the evaluation stack in the argument slot at a specified index.
+
+
+ Index of the argument to store the value in.
+
+ Depending on that index emits either Starg_S or Starg instruction.
+
+
+
+
+ Load an argument address onto the evaluation stack.
+
+
+ Index of the argument to load address of.
+
+ Depending on that index emits either Ldarga_S or Ldarga instruction.
+
+
+
+
+ Pushes a supplied value of type int32 onto the evaluation stack as an int32.
+
+
+ The value to push.
+
+ Depending on the value emits one of the following instructions:
+
+ Ldc_I4_0, Ldc_I4_1, Ldc_I4_2, Ldc_I4_3,
+ Ldc_I4_4, Ldc_I4_5, Ldc_I4_6, Ldc_I4_7,
+ Ldc_I4_8, Ldc_I4_M1, Ldc_I4_S, Ldc_I4
+
+
+
+
+ Pushes a supplied value of type int64 onto the evaluation stack as an int64.
+
+ The value to push.
+
+
+
+ Pushes a supplied value of type float32 onto the evaluation stack as type F (float).
+
+ The value to push.
+
+
+
+ Pushes a supplied value of type float64 onto the evaluation stack as type F (float).
+
+ The value to push.
+
+
+
+ Pushes a supplied value of type IntPtr onto the evaluation stack as type native int
+
+ The value to push.
+
+
+
+ Pushes the number of elements of a zero-based, one-dimensional array onto the evaluation stack.
+
+
+
+
+ Pushes an unmanaged pointer (type native int) to the native code implementing a specific method onto the evaluation stack.
+
+ The method to load address of.
+
+
+
+ Replaces the value of a field with a value from the evaluation stack.
+
+
+ The field to store value in.
+
+ Depending on whether the field is static or not emits either Stsfld or Stfld respectively.
+
+
+
+
+ Pushes the value of a field onto the evaluation stack.
+
+
+ The field to load value of.
+
+ Depending on whether the field is static or not emits either Ldsfld or Ldfld respectively.
+
+
+
+
+ Pushes the address of a field onto the evaluation stack.
+
+
+ The field to load address of.
+
+ Depending on whether the field is static or not emits either Ldsflda or Ldflda respectively.
+
+
+
+
+ Loads the address of the array element at a specified array index onto the top of the evaluation stack as type & (managed pointer).
+
+ The element type of the array.
+
+
+
+ Loads the element at a specified array index onto the top of the evaluation stack.
+
+
+ The element type of the array.
+
+ Depending on that type emits one of the following instructions:
+
+ Ldelem_Ref, Ldelem_I, Ldelem_I1, Ldelem_I2,
+ Ldelem_I4, Ldelem_I8, Ldelem_U1, Ldelem_U2,
+ Ldelem_U4, Ldelem_R4, Ldelem_R8
+
+ If the element type is a user-defined value type emits Ldelema & Ldobj instructions.
+
+
+
+
+ Replaces the array element at a given index with the value on the evaluation stack.
+
+
+ The element type of the array.
+
+ Depending on that type emits one of the following instructions:
+
+ Stelem_Ref, Stelem_I, Stelem_I1, Stelem_I2,
+ Stelem_I4, Stelem_I8, Stelem_R4, Stelem_R8
+
+ DOES NOT WORK if the element type is a user-defined value type. In such a case emit Ldelema & Stobj instructions.
+
+
+
+
+ Stores a value of a specified type at a specified address.
+
+
+ The type of a value being stored.
+
+ Depending on that type emits one of the following instructions:
+
+ Stind_Ref, Stind_I1, Stind_I2, Stind_I4,
+ Stind_I8, Stind_R4, Stind_R8
+
+ If the value is of a user-defined value type emits Stobj instruction.
+
+
+
+
+ Loads a value of a specifed type onto the evaluation stack indirectly.
+
+
+ The Type of a value being loaded.
+
+ Depending on that type emits one of the following instructions:
+
+ Ldind_Ref, Ldind_I1, Ldind_I2, Ldind_I4,
+ Ldind_I8, Ldind_U1, Ldind_U2, Ldind_U4,
+ Ldind_R4, Ldind_R8
+
+ If the value is of a user-defined value type emits Ldobj instruction.
+
+
+
+
+ Copies a specified number bytes from a source address to a destination address.
+
+
+
+
+ Indicates that an address currently atop the evaluation stack might not be aligned to the natural size of the immediately following ldind, stind, ldfld, stfld, ldobj, stobj, initblk, or cpblk instruction.
+
+ The value of alignment. Must be 1, 2 or 4.
+
+
+
+ Converts a metadata token of a specified type to its runtime representation, pushing it onto the evaluation stack.
+
+ The Type object metadata token of which is being pushed onto the evaluation stack.
+
+
+
+ Converts a metadata token of a specified method to its runtime representation, pushing it onto the evaluation stack.
+
+ The MethodInfo object metadata token of which is being pushed onto the evaluation stack.
+
+
+
+ Converts a metadata token of a specified field to its runtime representation, pushing it onto the evaluation stack.
+
+ The FieldInfo object metadata token of which is being pushed onto the evaluation stack.
+
+
+
+ Attempts to cast an object passed by reference to the specified class.
+
+ The Type to cast an object to.
+
+
+
+ Tests whether an object reference (type O) is an instance of a particular class.
+
+ The Type to test.
+
+
+
+ Converts the boxed representation of a type specified in the instruction to its unboxed form.
+
+ The Type of boxed object. Must be a value type.
+
+
+
+ Converts a value type to an object reference (type O).
+
+ The Type of object to box.
+
+
+
+ Emits the Common Intermediate Language (CIL) necessary to call System.Console.WriteLine with the given local variable.
+
+ The Local to write.
+
+
+
+ Emits the Common Intermediate Language (CIL) to call System.Console.WriteLine with a string.
+
+ The String to write.
+
+
+
+ Copies a value of a specified type from the evaluation stack into a supplied memory address.
+
+ The Type of object to be stored.
+
+
+
+ Copies the value type object pointed to by an address to the top of the evaluation stack.
+
+ The Type of object to be loaded.
+
+
+
+ Creates a new object or a new instance of a value type, pushing an object reference (type O) onto the evaluation stack.
+
+ The Constructor to be called.
+
+
+
+ Pushes an object reference to a new zero-based, one-dimensional array whose elements are of a specific type onto the evaluation stack.
+
+ The Type of elements.
+
+
+
+ Compares two values. If they are equal, the integer value 1 (int32) is pushed onto the evaluation stack; otherwise 0 (int32) is pushed onto the evaluation stack.
+
+
+
+
+ Compares two values. If the first value is greater than the second, the integer value 1 (int32) is pushed onto the evaluation stack; otherwise 0 (int32) is pushed onto the evaluation stack.
+
+
+ The Type of the values being compared.
+
+ Emits either Cgt or Cgt_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Compares two values. If the first value is less than the second, the integer value 1 (int32) is pushed onto the evaluation stack; otherwise 0 (int32) is pushed onto the evaluation stack.
+
+
+ The Type of the values being compared.
+
+ Emits either Clt or Clt_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Computes the bitwise AND of two values and pushes the result onto the evaluation stack.
+
+
+
+
+ Compute the bitwise complement of the two integer values on top of the stack and pushes the result onto the evaluation stack.
+
+
+
+
+ Computes the bitwise XOR of the top two values on the evaluation stack, pushing the result onto the evaluation stack.
+
+
+
+
+ Adds two values and pushes the result onto the evaluation stack.
+
+
+
+
+ Adds two integers, performs an overflow check, and pushes the result onto the evaluation stack.
+
+
+ The Type of the values being added.
+
+ Emits either Add_Ovf or Add_Ovf_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Subtracts one value from another and pushes the result onto the evaluation stack.
+
+
+
+
+ Subtracts one integer value from another, performs an overflow check, and pushes the result onto the evaluation stack.
+
+
+ The Type of the values being subtracted.
+
+ Emits either Sub_Ovf or Sub_Ovf_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Multiplies two values and pushes the result on the evaluation stack.
+
+
+
+
+ Multiplies two integer values, performs an overflow check, and pushes the result onto the evaluation stack.
+
+
+ The Type of the values being multiplied.
+
+ Emits either Mul_Ovf or Mul_Ovf_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Divides two values and pushes the result as a floating-point (type F) or quotient (type int32) onto the evaluation stack.
+
+
+ The Type of the values being divided.
+
+ Emits either Div or Div_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Divides two values and pushes the remainder onto the evaluation stack.
+
+
+ The Type of the values being divided.
+
+ Emits either Rem or Rem_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Shifts an integer value to the left (in zeroes) by a specified number of bits, pushing the result onto the evaluation stack.
+
+
+
+
+ Shifts an integer value to the right by a specified number of bits, pushing the result onto the evaluation stack.
+
+
+ The Type of the value being shifted.
+
+ Emits either Shr or Shr_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Negates a value and pushes the result onto the evaluation stack.
+
+
+
+
+ Computes the bitwise complement of the integer value on top of the stack and pushes the result onto the evaluation stack as the same type.
+
+
+
+
+ Pushes a new object reference to a string literal stored in the metadata.
+
+ The value to push.
+
+
+
+ Converts the value on top of the evaluation stack to int8, then extends (pads) it to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int8, and extends it to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to int16, then extends (pads) it to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int16, and extends it to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int32, and extends it to int32.
+
+
+
+
+ Converts the value on top of the evaluation stack to int64.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int64, and extends it to int64.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned native int, and extends it to native int.
+
+
+
+
+ Converts the value on top of the evaluation stack to float32.
+
+
+
+
+ Converts the value on top of the evaluation stack to float64.
+
+
+
+
+ Converts the unsigned integer value on top of the evaluation stack to float32.
+
+
+
+
+ Converts the value on top of the evaluation stack to signed int8 and extends it to int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_I1 or Conv_Ovf_I1_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to signed int16 and extending it to int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_I2 or Conv_Ovf_I2_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to signed int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_I4 or Conv_Ovf_I4_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to signed int64, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_I8 or Conv_Ovf_I8_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int8 and extends it to int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_U1 or Conv_Ovf_U1_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int16 and extends it to int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_U2 or Conv_Ovf_U2_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int32, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_U4 or Conv_Ovf_U4_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Converts the value on top of the evaluation stack to unsigned int64, throwing OverflowException on overflow.
+
+
+ The Type of the value being converted.
+
+ Emits either Conv_Ovf_U8 or Conv_Ovf_U8_Un instruction depending on whether the type is signed or not.
+
+
+
+
+ Calls the method indicated by the passed method descriptor.
+
+ Emits a Call or Callvirt instruction depending on whether the method is a virtual or not.
+
+ The Method to be called.
+ The Type of an object to call the method on
+ The types of the optional arguments if the method is a varargs method; otherwise, null.
+
+
+
+ Calls the constructor indicated by the passed constructor descriptor.
+
+ The Constructor to be called.
+
+
+
+ Calls a late-bound method on an object, pushing the return value onto the evaluation stack.
+
+ The Method to be called.
+ The Type of an object to call the method on
+ The types of the optional arguments if the method is a varargs method; otherwise, null.
+
+
+
+ Statically calls the method indicated by the passed method descriptor.
+
+ The Method to be called.
+ The types of the optional arguments if the method is a varargs method; otherwise, null.
+
+
+
+ Calls the method indicated on the evaluation stack (as a pointer to an entry point) with arguments described by a calling convention.
+
+ The managed calling convention to be used.
+ The Type of the result.
+ The types of the required arguments to the instruction.
+ The types of the optional arguments for varargs calls.
+
+
+
diff --git a/09-NoSQL/Assemblies/GrEmit.dll b/09-NoSQL/Assemblies/GrEmit.dll
new file mode 100644
index 0000000..ac21c30
Binary files /dev/null and b/09-NoSQL/Assemblies/GrEmit.dll differ
diff --git a/09-NoSQL/Assemblies/GrEmit.pdb b/09-NoSQL/Assemblies/GrEmit.pdb
new file mode 100644
index 0000000..bec3e4f
Binary files /dev/null and b/09-NoSQL/Assemblies/GrEmit.pdb differ
diff --git a/09-NoSQL/Assemblies/GroBuf.dll b/09-NoSQL/Assemblies/GroBuf.dll
new file mode 100644
index 0000000..cb97b7d
Binary files /dev/null and b/09-NoSQL/Assemblies/GroBuf.dll differ
diff --git a/09-NoSQL/Assemblies/GroBuf.pdb b/09-NoSQL/Assemblies/GroBuf.pdb
new file mode 100644
index 0000000..adce5d1
Binary files /dev/null and b/09-NoSQL/Assemblies/GroBuf.pdb differ
diff --git a/09-NoSQL/Assemblies/GroboContainer.dll b/09-NoSQL/Assemblies/GroboContainer.dll
new file mode 100644
index 0000000..016b290
Binary files /dev/null and b/09-NoSQL/Assemblies/GroboContainer.dll differ
diff --git a/09-NoSQL/Assemblies/GroboContainer.pdb b/09-NoSQL/Assemblies/GroboContainer.pdb
new file mode 100644
index 0000000..55158fd
Binary files /dev/null and b/09-NoSQL/Assemblies/GroboContainer.pdb differ
diff --git a/09-NoSQL/Assemblies/WebPersonal.Core.dll b/09-NoSQL/Assemblies/WebPersonal.Core.dll
new file mode 100644
index 0000000..68fb3a3
Binary files /dev/null and b/09-NoSQL/Assemblies/WebPersonal.Core.dll differ
diff --git a/09-NoSQL/Assemblies/WebPersonal.Core.pdb b/09-NoSQL/Assemblies/WebPersonal.Core.pdb
new file mode 100644
index 0000000..bcb7196
Binary files /dev/null and b/09-NoSQL/Assemblies/WebPersonal.Core.pdb differ
diff --git a/09-NoSQL/Assemblies/log4net.dll b/09-NoSQL/Assemblies/log4net.dll
new file mode 100644
index 0000000..ffc57e1
Binary files /dev/null and b/09-NoSQL/Assemblies/log4net.dll differ
diff --git a/09-NoSQL/Assemblies/nunit.framework.dll b/09-NoSQL/Assemblies/nunit.framework.dll
new file mode 100644
index 0000000..2a0a0aa
Binary files /dev/null and b/09-NoSQL/Assemblies/nunit.framework.dll differ
diff --git a/09-NoSQL/Assemblies/nunit.framework.xml b/09-NoSQL/Assemblies/nunit.framework.xml
new file mode 100644
index 0000000..911ebf8
--- /dev/null
+++ b/09-NoSQL/Assemblies/nunit.framework.xml
@@ -0,0 +1,5622 @@
+
+
+
+ nunit.framework
+
+
+
+
+ EmptyStringConstraint tests whether a string is empty.
+
+
+
+
+ EmptyConstraint tests a whether a string or collection is empty,
+ postponing the decision about which test is applied until the
+ type of the actual argument is known.
+
+
+
+
+ The Constraint class is the base of all built-in or
+ user-defined constraints in NUnit. It provides the operator
+ overloads used to combine constraints.
+
+
+
+
+ Static UnsetObject used to detect derived constraints
+ failing to set the actual value.
+
+
+
+
+ If true, all string comparisons will ignore case
+
+
+
+
+ If true, strings in error messages will be clipped
+
+
+
+
+ If true, arrays will be treated as collections, allowing
+ those of different dimensions to be compared
+
+
+
+
+ If non-zero, equality comparisons within the specified
+ tolerance will succeed.
+
+
+
+
+ IComparer object used in comparisons for some constraints.
+
+
+
+
+ The actual value being tested against a constraint
+
+
+
+
+ Flag the constraint to use a tolerance when determining equality.
+ Currently only used for doubles and floats.
+
+ Tolerance to be used
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Write the failure message to the MessageWriter provided
+ as an argument. The default implementation simply passes
+ the constraint and the actual value to the writer, which
+ then displays the constraint description and the value.
+
+ Constraints that need to provide additional details,
+ such as where the error occured can override this.
+
+ The MessageWriter on which to display the message
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Write the actual value for a failing constraint test to a
+ MessageWriter. The default implementation simply writes
+ the raw value of actual, leaving it to the writer to
+ perform any formatting.
+
+ The writer on which the actual value is displayed
+
+
+
+ This operator creates a constraint that is satisfied only if both
+ argument constraints are satisfied.
+
+
+
+
+ This operator creates a constraint that is satisfied if either
+ of the argument constraints is satisfied.
+
+
+
+
+ This operator creates a constraint that is satisfied if the
+ argument constraint is not satisfied.
+
+
+
+
+ Flag the constraint to ignore case and return self.
+
+
+
+
+ Flag the constraint to suppress string clipping
+ and return self.
+
+
+
+
+ Flag the constraint to compare arrays as collections
+ and return self.
+
+
+
+
+ Class used to detect any derived constraints
+ that fail to set the actual value in their
+ Matches override.
+
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ SubstringConstraint can test whether a string contains
+ the expected substring.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ StartsWithConstraint can test whether a string starts
+ with an expected substring.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected string
+
+
+
+ Test whether the constraint is matched by the actual value.
+ This is a template method, which calls the IsMatch method
+ of the derived class.
+
+
+
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ EndsWithConstraint can test whether a string ends
+ with an expected substring.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected string
+
+
+
+ Test whether the constraint is matched by the actual value.
+ This is a template method, which calls the IsMatch method
+ of the derived class.
+
+
+
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ RegexConstraint can test whether a string matches
+ the pattern provided.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The pattern.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ ConstraintBuilder is used to resolve the Not and All properties,
+ which serve as prefix operators for constraints. With the addition
+ of an operand stack, And and Or could be supported, but we have
+ left them out in favor of a simpler, more type-safe implementation.
+ Use the & and | operator overloads to combine constraints.
+
+
+
+
+ Implicitly convert ConstraintBuilder to an actual Constraint
+ at the point where the syntax demands it.
+
+
+
+
+
+
+ Resolves the chain of constraints using an
+ EqualConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ SameAsConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ LessThanConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ GreaterThanConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ LessThanOrEqualConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ LessThanOrEqualConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ GreaterThanOrEqualConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ GreaterThanOrEqualConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using an
+ ExactTypeConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using an
+ InstanceOfTypeConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using an
+ AssignableFromConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ ContainsConstraint as base. This constraint
+ will, in turn, make use of the appropriate
+ second-level constraint, depending on the
+ type of the actual argument.
+
+
+
+
+ Resolves the chain of constraints using a
+ CollectionContainsConstraint as base.
+
+ The expected object
+
+
+
+ Resolves the chain of constraints using a
+ StartsWithConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ StringEndingConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ StringMatchingConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ CollectionEquivalentConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ CollectionContainingConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ CollectionSubsetConstraint as base.
+
+
+
+
+ Resolves the chain of constraints using a
+ PropertyConstraint as base
+
+
+
+
+ Resolves the chain of constraints using a
+ PropertyCOnstraint on Length as base
+
+
+
+
+
+
+ Resolves the chain of constraints using a
+ PropertyCOnstraint on Length as base
+
+
+
+
+
+
+ Modifies the ConstraintBuilder by pushing a Prop operator on the
+ ops stack and the name of the property on the opnds stack.
+
+
+
+
+
+
+ Resolve a constraint that has been recognized by applying
+ any pending operators and returning the resulting Constraint.
+
+ A constraint that incorporates all pending operators
+
+
+
+ Resolves the chain of constraints using
+ EqualConstraint(null) as base.
+
+
+
+
+ Resolves the chain of constraints using
+ EqualConstraint(true) as base.
+
+
+
+
+ Resolves the chain of constraints using
+ EqualConstraint(false) as base.
+
+
+
+
+ Resolves the chain of constraints using
+ Is.NaN as base.
+
+
+
+
+ Resolves the chain of constraints using
+ Is.Empty as base.
+
+
+
+
+ Resolves the chain of constraints using
+ Is.Unique as base.
+
+
+
+
+ Modifies the ConstraintBuilder by pushing a Not operator on the stack.
+
+
+
+
+ Modifies the ConstraintBuilder by pushing a Not operator on the stack.
+
+
+
+
+ Modifies the ConstraintBuilder by pushing an All operator on the stack.
+
+
+
+
+ Modifies the ConstraintBuilder by pushing a Some operator on the stack.
+
+
+
+
+ Modifies the constraint builder by pushing All and Not operators on the stack
+
+
+
+
+ CollectionConstraint is the abstract base class for
+ constraints that operate on collections.
+
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Protected method to be implemented by derived classes
+
+
+
+
+
+
+ CollectionTally counts (tallies) the number of
+ occurences of each object in one or more enuerations.
+
+
+
+
+ Construct a CollectionTally object from a collection
+
+
+
+
+
+ Remove the counts for a collection from the tally,
+ so long as their are sufficient items to remove.
+ The tallies are not permitted to become negative.
+
+ The collection to remove
+ True if there were enough items to remove, otherwise false
+
+
+
+ Test whether all the counts are equal to a given value
+
+ The value to be looked for
+ True if all counts are equal to the value, otherwise false
+
+
+
+ Get the count of the number of times an object is present in the tally
+
+
+
+
+ EmptyCollectionConstraint tests whether a colletion is empty.
+
+
+
+
+ Check that the collection is empty
+
+
+
+
+
+
+ Write the constraint description to a MessageWriter
+
+
+
+
+
+ UniqueItemsConstraint tests whether all the items in a
+ collection are unique.
+
+
+
+
+ Check that all items are unique.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ CollectionContainsConstraint is used to test whether a collection
+ contains an expected object as a member.
+
+
+
+
+ Construct a CollectionContainsConstraint
+
+
+
+
+
+ Test whether the expected item is contained in the collection
+
+
+
+
+
+
+ Write a descripton of the constraint to a MessageWriter
+
+
+
+
+
+ CollectionEquivalentCOnstraint is used to determine whether two
+ collections are equivalent.
+
+
+
+
+ Construct a CollectionEquivalentConstraint
+
+
+
+
+
+ Test whether two collections are equivalent
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ CollectionSubsetConstraint is used to determine whether
+ one collection is a subset of another
+
+
+
+
+ Construct a CollectionSubsetConstraint
+
+ The collection that the actual value is expected to be a subset of
+
+
+
+ Test whether the actual collection is a subset of
+ the expected collection provided.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ EqualConstraint is able to compare an actual value with the
+ expected value provided in its constructor.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write a failure message. Overridden to provide custom
+ failure messages for EqualConstraint.
+
+ The MessageWriter to write to
+
+
+
+ Write description of this constraint
+
+ The MessageWriter to write to
+
+
+
+ Helper method to compare two arrays
+
+
+
+
+ Method to compare two DirectoryInfo objects
+
+ first directory to compare
+ second directory to compare
+ true if equivalent, false if not
+
+
+
+ Display the failure information for two collections that did not match.
+
+ The MessageWriter on which to display
+ The expected collection.
+ The actual collection
+ The depth of this failure in a set of nested collections
+
+
+
+ Displays a single line showing the types and sizes of the expected
+ and actual collections or arrays. If both are identical, the value is
+ only shown once.
+
+ The MessageWriter on which to display
+ The expected collection or array
+ The actual collection or array
+ The indentation level for the message line
+
+
+
+ Displays a single line showing the point in the expected and actual
+ arrays at which the comparison failed. If the arrays have different
+ structures or dimensions, both values are shown.
+
+ The MessageWriter on which to display
+ The expected array
+ The actual array
+ Index of the failure point in the underlying collections
+ The indentation level for the message line
+
+
+
+ Abstract base class used for prefixes
+
+
+
+
+ The base constraint
+
+
+
+
+ Construct given a base constraint
+
+
+
+
+
+ Set all modifiers applied to the prefix into
+ the base constraint before matching
+
+
+
+
+ NotConstraint negates the effect of some other constraint
+
+
+
+
+ Initializes a new instance of the class.
+
+ The base constraint to be negated.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for if the base constraint fails, false if it succeeds
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Write the actual value for a failing constraint test to a MessageWriter.
+
+ The writer on which the actual value is displayed
+
+
+
+ AllItemsConstraint applies another constraint to each
+ item in a collection, succeeding if they all succeed.
+
+
+
+
+ Construct an AllItemsConstraint on top of an existing constraint
+
+
+
+
+
+ Apply the item constraint to each item in the collection,
+ failing if any item fails.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ SomeItemsConstraint applies another constraint to each
+ item in a collection, succeeding if any of them succeeds.
+
+
+
+
+ Construct a SomeItemsConstraint on top of an existing constraint
+
+
+
+
+
+ Apply the item constraint to each item in the collection,
+ failing if any item fails.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ SomeItemsConstraint applies another constraint to each
+ item in a collection, succeeding if any of them succeeds.
+
+
+
+
+ Construct a SomeItemsConstraint on top of an existing constraint
+
+
+
+
+
+ Apply the item constraint to each item in the collection,
+ failing if any item fails.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ SameAsConstraint tests whether an object is identical to
+ the object passed to its constructor
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected object.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ TypeConstraint is the abstract base for constraints
+ that take a Type as their expected value.
+
+
+
+
+ The expected Type used by the constraint
+
+
+
+
+ Construct a TypeConstraint for a given Type
+
+
+
+
+
+ Write the actual value for a failing constraint test to a
+ MessageWriter. TypeCOnstraints override this method to write
+ the name of the type.
+
+ The writer on which the actual value is displayed
+
+
+
+ ExactTypeConstraint is used to test that an object
+ is of the exact type provided in the constructor
+
+
+
+
+ Construct an ExactTypeConstraint for a given Type
+
+
+
+
+
+ Test that an object is of the exact type specified
+
+
+
+
+
+
+ Write the description of this constraint to a MessageWriter
+
+
+
+
+
+ InstanceOfTypeConstraint is used to test that an object
+ is of the same type provided or derived from it.
+
+
+
+
+ Construct an InstanceOfTypeConstraint for the type provided
+
+
+
+
+
+ Test whether an object is of the specified type or a derived type
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ AssignableFromConstraint is used to test that an object
+ can be assigned from a given Type.
+
+
+
+
+ Construct an AssignableFromConstraint for the type provided
+
+
+
+
+
+ Test whether an object can be assigned from the specified type
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ Abstract base class for constraints that compare values to
+ determine if one is greater than, equal to or less than
+ the other.
+
+
+
+
+ The value against which a comparison is to be made
+
+
+
+
+ If true, less than returns success
+
+
+
+
+ if true, equal returns success
+
+
+
+
+ if true, greater than returns success
+
+
+
+
+ The predicate used as a part of the description
+
+
+
+
+ Initializes a new instance of the class.
+
+ The value against which to make a comparison.
+ if set to true less succeeds.
+ if set to true equal succeeds.
+ if set to true greater succeeds.
+ String used in describing the constraint.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Tests whether a value is greater than the value supplied to its constructor
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ Tests whether a value is greater than or equal to the value supplied to its constructor
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ Tests whether a value is less than the value supplied to its constructor
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ Tests whether a value is less than or equal to the value supplied to its constructor
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ The Numerics class contains common operations on numeric values.
+
+
+
+
+ Checks the type of the object, returning true if
+ the object is a numeric type.
+
+ The object to check
+ true if the object is a numeric type
+
+
+
+ Checks the type of the object, returning true if
+ the object is a floating point numeric type.
+
+ The object to check
+ true if the object is a floating point numeric type
+
+
+
+ Checks the type of the object, returning true if
+ the object is a fixed point numeric type.
+
+ The object to check
+ true if the object is a fixed point numeric type
+
+
+
+ Test two numeric values for equality, performing the usual numeric
+ conversions and using a provided or default tolerance. If the value
+ referred to by tolerance is null, this method may set it to a default.
+
+ The expected value
+ The actual value
+ A reference to the numeric tolerance in effect
+ True if the values are equal
+
+
+
+ Compare two numeric values, performing the usual numeric conversions.
+
+ The expected value
+ The actual value
+
+
+
+
+ ContainsConstraint tests a whether a string contains a substring
+ or a collection contains an object. It postpones the decision of
+ which test to use until the type of the actual argument is known.
+ This allows testing whether a string is contained in a collection
+ or as a substring of another string using the same syntax.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Summary description for PropertyConstraint.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The name.
+ The constraint to apply to the property.
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ Write the actual value for a failing constraint test to a
+ MessageWriter. The default implementation simply writes
+ the raw value of actual, leaving it to the writer to
+ perform any formatting.
+
+ The writer on which the actual value is displayed
+
+
+
+ BinaryOperation is the abstract base of all constraints
+ that combine two other constraints in some fashion.
+
+
+
+
+ The first constraint being combined
+
+
+
+
+ The second constraint being combined
+
+
+
+
+ Construct a BinaryOperation from two other constraints
+
+ The first constraint
+ The second constraint
+
+
+
+ AndConstraint succeeds only if both members succeed.
+
+
+
+
+ Create an AndConstraint from two other constraints
+
+ The first constraint
+ The second constraint
+
+
+
+ Apply both member constraints to an actual value, succeeding
+ succeeding only if both of them succeed.
+
+ The actual value
+ True if the constraints both succeeded
+
+
+
+ Write a description for this contraint to a MessageWriter
+
+ The MessageWriter to receive the description
+
+
+
+ OrConstraint succeeds if either member succeeds
+
+
+
+
+ Create an OrConstraint from two other constraints
+
+ The first constraint
+ The second constraint
+
+
+
+ Apply the member constraints to an actual value, succeeding
+ succeeding as soon as one of them succeeds.
+
+ The actual value
+ True if either constraint succeeded
+
+
+
+ Write a description for this contraint to a MessageWriter
+
+ The MessageWriter to receive the description
+
+
+
+ The Is class is a helper class with properties and methods
+ that supply a number of constraints used in Asserts.
+
+
+
+
+ Is.Null returns a static constraint that tests for null
+
+
+
+
+ Is.True returns a static constraint that tests whether a value is true
+
+
+
+
+ Is.False returns a static constraint that tests whether a value is false
+
+
+
+
+ Is.NaN returns a static constraint that tests whether a value is an NaN
+
+
+
+
+ Is.Empty returns a static constraint that tests whether a string or collection is empty
+
+
+
+
+ Is.Unique returns a static constraint that tests whether a collection contains all unque items.
+
+
+
+
+ Is.EqualTo returns a constraint that tests whether the
+ actual value equals the supplied argument
+
+
+
+
+
+
+ Is.SameAs returns a constraint that tests whether the
+ actual value is the same object as the supplied argument.
+
+
+
+
+
+
+ Is.GreaterThan returns a constraint that tests whether the
+ actual value is greater than the suppled argument
+
+
+
+
+ Is.GreaterThanOrEqualTo returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Is.AtLeast is a synonym for Is.GreaterThanOrEqualTo
+
+
+
+
+ Is.LessThan returns a constraint that tests whether the
+ actual value is less than the suppled argument
+
+
+
+
+ Is.LessThanOrEqualTo returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Is.AtMost is a synonym for Is.LessThanOrEqualTo
+
+
+
+
+ Is.TypeOf returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Is.InstanceOfType returns a constraint that tests whether
+ the actual value is of the type supplied as an argument
+ or a derived type.
+
+
+
+
+ Is.AssignableFrom returns a constraint that tests whether
+ the actual value is assignable from the type supplied as
+ an argument.
+
+
+
+
+
+
+ Is.EquivalentTo returns a constraint that tests whether
+ the actual value is a collection containing the same
+ elements as the collection supplied as an arument
+
+
+
+
+ Is.SubsetOf returns a constraint that tests whether
+ the actual value is a subset of the collection
+ supplied as an arument
+
+
+
+
+ Is.Not returns a ConstraintBuilder that negates
+ the constraint that follows it.
+
+
+
+
+ Is.All returns a ConstraintBuilder, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed. This property is
+ a synonym for Has.AllItems.
+
+
+
+
+ The Iz class is a synonym for Is intended for use in VB,
+ which regards Is as a keyword.
+
+
+
+
+ The Text class is a helper class with properties and methods
+ that supply a number of constraints used with strings.
+
+
+
+
+ Contains returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ DoesNotContain returns a constraint that fails if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ StartsWith returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ DoesNotStartWith returns a constraint that fails if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ EndsWith returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ DoesNotEndWith returns a constraint that fails if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Matches returns a constraint that succeeds if the actual
+ value matches the pattern supplied as an argument.
+
+
+
+
+
+
+ DoesNotMatch returns a constraint that failss if the actual
+ value matches the pattern supplied as an argument.
+
+
+
+
+
+
+ Text.All returns a ConstraintBuilder, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ The List class is a helper class with properties and methods
+ that supply a number of constraints used with lists and collections.
+
+
+
+
+ List.Map returns a ListMapper, which can be used to map
+ the original collection to another collection.
+
+
+
+
+
+
+ ListMapper is used to transform a collection used as an actual argument
+ producing another collection to be used in the assertion.
+
+
+
+
+ Construct a ListMapper based on a collection
+
+ The collection to be transformed
+
+
+
+ Produces a collection containing all the values of a property
+
+ The collection of property values
+
+
+
+
+ Summary description for HasNoPrefixB.
+
+
+
+
+ Returns a new ConstraintBuilder, which will apply the
+ following constraint to a named property of the object
+ being tested.
+
+ The name of the property
+
+
+
+ Returns a new PropertyConstraint checking for the
+ existence of a particular property value.
+
+ The name of the property to look for
+ The expected value of the property
+
+
+
+ Returns a new PropertyConstraint for the Length property
+
+
+
+
+
+
+ Returns a new PropertyConstraint or the Count property
+
+
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+ The expected object
+
+
+
+ Has.No returns a ConstraintBuilder that negates
+ the constraint that follows it.
+
+
+
+
+ Has.AllItems returns a ConstraintBuilder, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ Has.Some returns a ConstraintBuilder, which will apply
+ the following constraint to all members of a collection,
+ succeeding if any of them succeed. It is a synonym
+ for Has.Item.
+
+
+
+
+ Has.None returns a ConstraintBuilder, which will apply
+ the following constraint to all members of a collection,
+ succeeding only if none of them succeed.
+
+
+
+
+ Nested class that allows us to restrict the number
+ of key words that may appear after Has.No.
+
+
+
+
+ Return a ConstraintBuilder conditioned to apply
+ the following constraint to a property.
+
+ The property name
+ A ConstraintBuilder
+
+
+
+ Return a Constraint that succeeds if the expected object is
+ not contained in a collection.
+
+ The expected object
+ A Constraint
+
+
+
+ The Assert class contains a collection of static methods that
+ implement the most common assertions used in NUnit.
+
+
+
+
+ We don't actually want any instances of this object, but some people
+ like to inherit from it to add other static methods. Hence, the
+ protected constructor disallows any instances of this object.
+
+
+
+
+ The Equals method throws an AssertionException. This is done
+ to make sure there is no mistake by calling this function.
+
+
+
+
+
+
+ override the default ReferenceEquals to throw an AssertionException. This
+ implementation makes sure there is no mistake in calling this function
+ as part of Assert.
+
+
+
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is false
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is false
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+
+
+
+ Asserts that a condition is false. If the condition is true the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is true
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is false. If the condition is true the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is true
+
+
+
+ Asserts that a condition is false. If the condition is true the method throws
+ an .
+
+ The evaluated condition
+
+
+
+ Verifies that the object that is passed in is not equal to null
+ If the object is null
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to be displayed when the object is null
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the object that is passed in is not equal to null
+ If the object is null
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to be displayed when the object is null
+
+
+
+ Verifies that the object that is passed in is not equal to null
+ If the object is null
then an
+ is thrown.
+
+ The object that is to be tested
+
+
+
+ Verifies that the object that is passed in is equal to null
+ If the object is not null
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to be displayed when the object is not null
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the object that is passed in is equal to null
+ If the object is not null
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to be displayed when the object is not null
+
+
+
+ Verifies that the object that is passed in is equal to null
+ If the object is not null null
then an
+ is thrown.
+
+ The object that is to be tested
+
+
+
+ Verifies that the double is passed is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+ The message to be displayed when the object is not null
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the double is passed is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to be displayed when the object is not null
+
+
+
+ Verifies that the double is passed is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The object that is to be tested
+
+
+
+ Assert that a string is empty - that is equal to string.Empty
+
+ The string to be tested
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that a string is empty - that is equal to string.Emtpy
+
+ The string to be tested
+ The message to be displayed on failure
+
+
+
+ Assert that a string is empty - that is equal to string.Emtpy
+
+ The string to be tested
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+ The message to be displayed on failure
+
+
+
+ Assert that an array,list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+
+
+
+ Assert that a string is not empty - that is not equal to string.Empty
+
+ The string to be tested
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that a string is empty - that is equal to string.Emtpy
+
+ The string to be tested
+ The message to be displayed on failure
+
+
+
+ Assert that a string is empty - that is equal to string.Emtpy
+
+ The string to be tested
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+ The message to be displayed on failure
+
+
+
+ Assert that an array,list or other collection is empty
+
+ An array, list or other collection implementing ICollection
+
+
+
+ Asserts that an object may be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+
+
+
+ Asserts that an object may be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The messge to display in case of failure
+
+
+
+ Asserts that an object may be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Asserts that an object may not be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+
+
+
+ Asserts that an object may not be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The messge to display in case of failure
+
+
+
+ Asserts that an object may not be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+ A message to display in case of failure
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+ A message to display in case of failure
+ An array of objects to be used in formatting the message
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+ A message to display in case of failure
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+ A message to display in case of failure
+ An array of objects to be used in formatting the message
+
+
+
+ Verifies that two ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+
+
+
+ Verifies that two ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+
+
+
+ Verifies that two longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two uints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two uints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+
+
+
+ Verifies that two uints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two ulongs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two ulongs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+
+
+
+ Verifies that two ulongs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two decimals are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two decimal are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message that will be displayed on failure
+
+
+
+ Verifies that two decimals are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two doubles are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two doubles are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message that will be displayed on failure
+
+
+
+ Verifies that two doubles are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+
+
+
+ Verifies that two floats are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message displayed upon failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two floats are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message displayed upon failure
+
+
+
+ Verifies that two floats are equal considering a delta. If the
+ expected value is infinity then the delta value is ignored. If
+ they are not equals then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+
+
+
+ Verifies that two objects are equal. Two objects are considered
+ equal if both are null, or if both have the same value. All
+ non-numeric types are compared by using the Equals method.
+ Arrays are compared by comparing each element using the same rules.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display if objects are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two objects are equal. Two objects are considered
+ equal if both are null, or if both have the same value. All
+ non-numeric types are compared by using the Equals method.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display if objects are not equal
+
+
+
+ Verifies that two objects are equal. Two objects are considered
+ equal if both are null, or if both have the same value. All
+ non-numeric types are compared by using the Equals method.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+
+
+
+ Asserts that two objects are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two objects are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two objects are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two ints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two ints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two ints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two longss are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two longs are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two longs are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two uints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two uints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two uints are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two ulongs are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two ulongs are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two ulong are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two decimals are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two decimals are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two decimals are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two floats are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two floats are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two floats are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two doubles are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two doubles are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two doubles are not equal. If they are equal
+ an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two objects refer to the same object. If they
+ are not the same an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are not the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two objects refer to the same object. If they
+ are not the same an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the object is null
+
+
+
+ Asserts that two objects refer to the same object. If they
+ are not the same an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Asserts that two objects do not refer to the same object. If they
+ are the same an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the two objects are the same object.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two objects do not refer to the same object. If they
+ are the same an is thrown.
+
+ The expected object
+ The actual object
+ The message to be displayed when the objects are the same
+
+
+
+ Asserts that two objects do not refer to the same object. If they
+ are the same an is thrown.
+
+ The expected object
+ The actual object
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Asserts that an object is contained in a list.
+
+ The expected object
+ The list to be examined
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that an object is contained in a list.
+
+ The expected object
+ The list to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that an object is contained in a list.
+
+ The expected object
+ The list to be examined
+
+
+
+ Throws an with the message and arguments
+ that are passed in. This is used by the other Assert functions.
+
+ The message to initialize the with.
+ Arguments to be used in formatting the message
+
+
+
+ Throws an with the message that is
+ passed in. This is used by the other Assert functions.
+
+ The message to initialize the with.
+
+
+
+ Throws an .
+ This is used by the other Assert functions.
+
+
+
+
+ Throws an with the message and arguments
+ that are passed in. This causes the test to be reported as ignored.
+
+ The message to initialize the with.
+ Arguments to be used in formatting the message
+
+
+
+ Throws an with the message that is
+ passed in. This causes the test to be reported as ignored.
+
+ The message to initialize the with.
+
+
+
+ Throws an .
+ This causes the test to be reported as ignored.
+
+
+
+
+ NOTE: The use of asserters for extending NUnit has
+ now been replaced by the use of constraints. This
+ method is marked obsolete.
+
+ Test the condition asserted by an asserter and throw
+ an assertion exception using provided message on failure.
+
+ An object that implements IAsserter
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ A Constraint to be applied
+ The actual value to test
+
+
+
+ Apply a constraint to an actual value, succeedingt if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ A Constraint to be applied
+ The actual value to test
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to an actual value, succeedingt if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ A Constraint to be applied
+ The actual value to test
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is false
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display if the condition is false
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater or equal to than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater or equal to than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater or equal to than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than or equal to the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If they are not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+ The message that will be displayed on failure
+
+
+
+ Verifies that the first value is less than or equal to the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be less
+ The second value, expected to be greater
+
+
+
+ Gets the number of assertions executed so far and
+ resets the counter to zero.
+
+
+
+
+ Enumeration indicating how the expected message parameter is to be used
+
+
+
+ Expect an exact match
+
+
+ Expect a message containing the parameter string
+
+
+ Match the regular expression provided as a parameter
+
+
+
+ ExpectedExceptionAttribute
+
+
+
+
+
+ Constructor for a non-specific exception
+
+
+
+
+ Constructor for a given type of exception
+
+ The type of the expected exception
+
+
+
+ Constructor for a given exception name
+
+ The full name of the expected exception
+
+
+
+ Constructor for a given type of exception and expected message text
+
+ The type of the expected exception
+ The expected message text
+
+
+
+ Constructor for a given exception name and expected message text
+
+ The full name of the expected exception
+ The expected messge text
+
+
+
+ Gets or sets the expected exception type
+
+
+
+
+ Gets or sets the full Type name of the expected exception
+
+
+
+
+ Gets or sets the expected message text
+
+
+
+
+ Gets or sets the user message displayed in case of failure
+
+
+
+
+ Gets or sets the type of match to be performed on the expected message
+
+
+
+
+ Gets the name of a method to be used as an exception handler
+
+
+
+
+ A set of Assert methods operationg on one or more collections
+
+
+
+
+ The Equals method throws an AssertionException. This is done
+ to make sure there is no mistake by calling this function.
+
+
+
+
+
+
+ override the default ReferenceEquals to throw an AssertionException. This
+ implementation makes sure there is no mistake in calling this function
+ as part of Assert.
+
+
+
+
+
+
+ Asserts that all items contained in collection are of the type specified by expectedType.
+
+ IEnumerable containing objects to be considered
+ System.Type that all objects in collection must be instances of
+
+
+
+ Asserts that all items contained in collection are of the type specified by expectedType.
+
+ IEnumerable containing objects to be considered
+ System.Type that all objects in collection must be instances of
+ The message that will be displayed on failure
+
+
+
+ Asserts that all items contained in collection are of the type specified by expectedType.
+
+ IEnumerable containing objects to be considered
+ System.Type that all objects in collection must be instances of
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that all items contained in collection are not equal to null.
+
+ IEnumerable containing objects to be considered
+
+
+
+ Asserts that all items contained in collection are not equal to null.
+
+ IEnumerable containing objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that all items contained in collection are not equal to null.
+
+ IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Ensures that every object contained in collection exists within the collection
+ once and only once.
+
+ IEnumerable of objects to be considered
+
+
+
+ Ensures that every object contained in collection exists within the collection
+ once and only once.
+
+ IEnumerable of objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Ensures that every object contained in collection exists within the collection
+ once and only once.
+
+ IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are exactly equal. The collections must have the same count,
+ and contain the exact same objects in the same order.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+
+
+
+ Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are not exactly equal.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+
+
+
+ Asserts that expected and actual are not exactly equal.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+
+
+
+ Asserts that expected and actual are not exactly equal.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are not exactly equal.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are not exactly equal.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are not exactly equal.
+ If comparer is not null then it will be used to compare the objects.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The IComparer to use in comparing objects from each IEnumerable
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that expected and actual are not equivalent.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+
+
+
+ Asserts that expected and actual are not equivalent.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that expected and actual are not equivalent.
+
+ The first IEnumerable of objects to be considered
+ The second IEnumerable of objects to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that collection contains actual as an item.
+
+ IEnumerable of objects to be considered
+ Object to be found within collection
+
+
+
+ Asserts that collection contains actual as an item.
+
+ IEnumerable of objects to be considered
+ Object to be found within collection
+ The message that will be displayed on failure
+
+
+
+ Asserts that collection contains actual as an item.
+
+ IEnumerable of objects to be considered
+ Object to be found within collection
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that collection does not contain actual as an item.
+
+ IEnumerable of objects to be considered
+ Object that cannot exist within collection
+
+
+
+ Asserts that collection does not contain actual as an item.
+
+ IEnumerable of objects to be considered
+ Object that cannot exist within collection
+ The message that will be displayed on failure
+
+
+
+ Asserts that collection does not contain actual as an item.
+
+ IEnumerable of objects to be considered
+ Object that cannot exist within collection
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that superset is not a subject of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+
+
+
+ Asserts that superset is not a subject of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that superset is not a subject of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that superset is a subset of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+
+
+
+ Asserts that superset is a subset of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+ The message that will be displayed on failure
+
+
+
+ Asserts that superset is a subset of subset.
+
+ The IEnumerable superset to be considered
+ The IEnumerable subset to be considered
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+ The message to be displayed on failure
+
+
+
+ Assert that an array,list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+ The message to be displayed on failure
+
+
+
+ Assert that an array,list or other collection is empty
+
+ An array, list or other collection implementing IEnumerable
+
+
+
+ NOTE: The use of asserters for extending NUnit has
+ now been replaced by the use of constraints. This
+ class is marked obsolete.
+
+ AbstractAsserter is the base class for all asserters.
+ Asserters encapsulate a condition test and generation
+ of an AssertionException with a tailored message. They
+ are used by the Assert class as helper objects.
+
+ User-defined asserters may be passed to the
+ Assert.DoAssert method in order to implement
+ extended asserts.
+
+
+
+
+ NOTE: The use of asserters for extending NUnit has
+ now been replaced by the use of constraints. This
+ interface is marked obsolete.
+
+ The interface implemented by an asserter. Asserters
+ encapsulate a condition test and generation of an
+ AssertionException with a tailored message. They
+ are used by the Assert class as helper objects.
+
+ User-defined asserters may be passed to the
+ Assert.DoAssert method in order to implement
+ extended asserts.
+
+
+
+
+ Test the condition for the assertion.
+
+ True if the test succeeds
+
+
+
+ Return the message giving the failure reason.
+ The return value is unspecified if no failure
+ has occured.
+
+
+
+
+ The user-defined message for this asserter.
+
+
+
+
+ Arguments to use in formatting the user-defined message.
+
+
+
+
+ Our failure message object, initialized as needed
+
+
+
+
+ Constructs an AbstractAsserter
+
+ The message issued upon failure
+ Arguments to be used in formatting the message
+
+
+
+ Test method to be implemented by derived types.
+ Default always succeeds.
+
+ True if the test succeeds
+
+
+
+ AssertionFailureMessage object used internally
+
+
+
+
+ Message related to a failure. If no failure has
+ occured, the result is unspecified.
+
+
+
+
+ The Assertion class is obsolete and has been
+ replaced by the Assert class.
+
+
+
+
+ Asserts that a condition is true. If it isn't it throws
+ an .
+
+ The message to display is the condition
+ is false
+ The evaluated condition
+
+
+
+ Asserts that a condition is true. If it isn't it throws
+ an .
+
+ The evaluated condition
+
+
+
+ /// Asserts that two doubles are equal concerning a delta. If the
+ expected value is infinity then the delta value is ignored.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+
+
+
+ /// Asserts that two singles are equal concerning a delta. If the
+ expected value is infinity then the delta value is ignored.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+
+
+ Asserts that two objects are equal. If they are not
+ an is thrown.
+
+
+ Asserts that two ints are equal. If they are not
+ an is thrown.
+
+
+ Asserts that two ints are equal. If they are not
+ an is thrown.
+
+
+ Asserts that two doubles are equal concerning a delta.
+ If the expected value is infinity then the delta value is ignored.
+
+
+
+ Asserts that two floats are equal concerning a delta.
+ If the expected value is infinity then the delta value is ignored.
+
+
+
+
+ Asserts that two objects are equal. Two objects are considered
+ equal if both are null, or if both have the same value. Numeric
+ types are compared via string comparision on their contents to
+ avoid problems comparing values between different types. All
+ non-numeric types are compared by using the Equals method.
+ If they are not equal an is thrown.
+
+
+
+ Asserts that an object isn't null.
+
+
+ Asserts that an object isn't null.
+
+
+ Asserts that an object is null.
+
+
+ Asserts that an object is null.
+
+
+ Asserts that two objects refer to the same object. If they
+ are not the same an is thrown.
+
+
+
+ Asserts that two objects refer to the same object.
+ If they are not an is thrown.
+
+
+
+ Fails a test with no message.
+
+
+ Fails a test with the given message.
+
+
+
+ Thrown when an assertion failed.
+
+
+
+
+ The error message that explains
+ the reason for the exception
+
+
+ The error message that explains
+ the reason for the exception
+ The exception that caused the
+ current exception
+
+
+
+ Serialization Constructor
+
+
+
+
+ AssertionFailureMessage encapsulates a failure message
+ issued as a result of an Assert failure.
+
+
+
+
+ Number of characters before a highlighted position before
+ clipping will occur. Clipped text is replaced with an
+ elipsis "..."
+
+
+
+
+ Number of characters after a highlighted position before
+ clipping will occur. Clipped text is replaced with an
+ elipsis "..."
+
+
+
+
+ Prefix used to start an expected value line.
+ Must be same length as actualPrefix.
+
+
+
+
+ Prefix used to start an actual value line.
+ Must be same length as expectedPrefix.
+
+
+
+
+ Construct an AssertionFailureMessage with a message
+ and optional arguments.
+
+
+
+
+
+
+ Construct an empty AssertionFailureMessage
+
+
+
+
+ Add an expected value line to the message containing
+ the text provided as an argument.
+
+ Text describing what was expected.
+
+
+
+ Add an actual value line to the message containing
+ the text provided as an argument.
+
+ Text describing the actual value.
+
+
+
+ Add an expected value line to the message containing
+ a string representation of the object provided.
+
+ An object representing the expected value
+
+
+
+ Add an expected value line to the message containing a double
+ and the tolerance used in making the comparison.
+
+ The expected value
+ The tolerance specified in the Assert
+
+
+
+ Add an actual value line to the message containing
+ a string representation of the object provided.
+
+ An object representing what was actually found
+
+
+
+ Display two lines that communicate the expected value, and the actual value
+
+ The expected value
+ The actual value found
+
+
+
+ Display two lines that communicate the expected value, the actual value and
+ the tolerance used in comparing two doubles.
+
+ The expected value
+ The actual value found
+ The tolerance specified in the Assert
+
+
+
+ Draws a marker under the expected/actual strings that highlights
+ where in the string a mismatch occurred.
+
+ The position of the mismatch
+
+
+
+ Reports whether the string lengths are the same or different, and
+ what the string lengths are.
+
+ The expected string
+ The actual string value
+
+
+
+ Called to create additional message lines when two objects have been
+ found to be unequal. If the inputs are strings, a special message is
+ rendered that can help track down where the strings are different,
+ based on differences in length, or differences in content.
+
+ If the inputs are not strings, the ToString method of the objects
+ is used to show what is different about them.
+
+ The expected value
+ The actual value
+ True if a case-insensitive comparison is being performed
+
+
+
+ Called to create additional message lines when two doubles have been
+ found to be unequal, within the specified tolerance.
+
+
+
+
+ Constructs a message that can be displayed when the content of two
+ strings are different, but the string lengths are the same. The
+ message will clip the strings to a reasonable length, centered
+ around the first position where they are mismatched, and draw
+ a line marking the position of the difference to make comparison
+ quicker.
+
+ The expected string value
+ The actual string value
+ True if a case-insensitive comparison is being performed
+
+
+
+ Display a standard message showing the differences found between
+ two arrays that were expected to be equal.
+
+ The expected array value
+ The actual array value
+ The index at which a difference was found
+
+
+
+ Display a standard message showing the differences found between
+ two collections that were expected to be equal.
+
+ The expected collection value
+ The actual collection value
+ The index at which a difference was found
+
+
+
+ Get an array of indices representing the point in a collection or
+ array corresponding to a single int index into the collection.
+
+ The collection to which the indices apply
+ Index in the collection
+ Array of indices
+
+
+
+ Displays elements from a list on a line
+
+ Text to prefix the line with
+ The list of items to display
+ The index in the list of the first element to display
+ The maximum number of elements to display
+
+
+
+ Formats an object for display in a message line
+
+ The object to be displayed
+
+
+
+
+ Tests two objects to determine if they are strings.
+
+
+
+
+
+
+
+ Renders up to M characters before, and up to N characters after
+ the specified index position. If leading or trailing text is
+ clipped, and elipses "..." is added where the missing text would
+ be.
+
+ Clips strings to limit previous or post newline characters,
+ since these mess up the comparison
+
+
+
+
+
+
+
+ Shows the position two strings start to differ. Comparison
+ starts at the start index.
+
+
+
+
+ -1 if no mismatch found, or the index where mismatch found
+
+
+
+ Turns CR, LF, or TAB into visual indicator to preserve visual marker
+ position. This is done by replacing the '\r' into '\\' and 'r'
+ characters, and the '\n' into '\\' and 'n' characters, and '\t' into
+ '\\' and 't' characters.
+
+ Thus the single character becomes two characters for display.
+
+
+
+
+
+
+ Attribute used to apply a category to a test
+
+
+
+
+ The name of the category
+
+
+
+
+ Construct attribute for a given category
+
+ The name of the category
+
+
+
+ Protected constructor uses the Type name as the name
+ of the category.
+
+
+
+
+ The name of the category
+
+
+
+
+ Abstract base for Attributes that are used to include tests
+ in the test run based on environmental settings.
+
+
+
+
+ Constructor with no included items specified, for use
+ with named property syntax.
+
+
+
+
+ Constructor taking one or more included items
+
+ Comma-delimited list of included items
+
+
+
+ Name of the item that is needed in order for
+ a test to run. Multiple itemss may be given,
+ separated by a comma.
+
+
+
+
+ Name of the item to be excluded. Multiple items
+ may be given, separated by a comma.
+
+
+
+
+ The reason for including or excluding the test
+
+
+
+
+ PlatformAttribute is used to mark a test fixture or an
+ individual method as applying to a particular platform only.
+
+
+
+
+ Constructor with no platforms specified, for use
+ with named property syntax.
+
+
+
+
+ Constructor taking one or more platforms
+
+ Comma-deliminted list of platforms
+
+
+
+ CultureAttribute is used to mark a test fixture or an
+ individual method as applying to a particular Culture only.
+
+
+
+
+ Constructor with no cultures specified, for use
+ with named property syntax.
+
+
+
+
+ Constructor taking one or more cultures
+
+ Comma-deliminted list of cultures
+
+
+
+ MessageWriter is the abstract base for classes that write
+ constraint descriptions and messages in some form. The
+ class has separate methods for writing various components
+ of a message, allowing implementations to tailor the
+ presentation as needed.
+
+
+
+
+ Construct a MessageWriter given a culture
+
+
+
+
+ Method to write single line message with optional args, usually
+ written to precede the general failure message.
+
+ The message to be written
+ Any arguments used in formatting the message
+
+
+
+ Method to write single line message with optional args, usually
+ written to precede the general failure message, at a givel
+ indentation level.
+
+ The indentation level of the message
+ The message to be written
+ Any arguments used in formatting the message
+
+
+
+ Display Expected and Actual lines for a constraint. This
+ is called by MessageWriter's default implementation of
+ WriteMessageTo and provides the generic two-line display.
+
+ The constraint that failed
+
+
+
+ Display Expected and Actual lines for given values. This
+ method may be called by constraints that need more control over
+ the display of actual and expected values than is provided
+ by the default implementation.
+
+ The expected value
+ The actual value causing the failure
+
+
+
+ Display Expected and Actual lines for given values, including
+ a tolerance value on the Expected line.
+
+ The expected value
+ The actual value causing the failure
+ The tolerance within which the test was made
+
+
+
+ Display the expected and actual string values on separate lines.
+ If the mismatch parameter is >=0, an additional line is displayed
+ line containing a caret that points to the mismatch point.
+
+ The expected string value
+ The actual string value
+ The point at which the strings don't match or -1
+ If true, case is ignored in locating the point where the strings differ
+ If true, the strings should be clipped to fit the line
+
+
+
+ Writes the text for a connector.
+
+ The connector.
+
+
+
+ Writes the text for a predicate.
+
+ The predicate.
+
+
+
+ Writes the text for an expected value.
+
+ The expected value.
+
+
+
+ Writes the text for a modifier
+
+ The modifier.
+
+
+
+ Writes the text for an actual value.
+
+ The actual value.
+
+
+
+ Writes the text for a generalized value.
+
+ The value.
+
+
+
+ Writes the text for a collection value,
+ starting at a particular point, to a max length
+
+ The collection containing elements to write.
+ The starting point of the elements to write
+ The maximum number of elements to write
+
+
+
+ Abstract method to get the max line length
+
+
+
+
+ Static methods used in creating messages
+
+
+
+
+ Static string used when strings are clipped
+
+
+
+
+ Returns the representation of a type as used in NUnitLite.
+ This is the same as Type.ToString() except for arrays,
+ which are displayed with their declared sizes.
+
+
+
+
+
+
+ Converts any control characters in a string
+ to their escaped representation.
+
+ The string to be converted
+ The converted string
+
+
+
+ Return the a string representation for a set of indices into an array
+
+ Array of indices for which a string is needed
+
+
+
+ Get an array of indices representing the point in a collection or
+ array corresponding to a single int index into the collection.
+
+ The collection to which the indices apply
+ Index in the collection
+ Array of indices
+
+
+
+ Clip a string to a given length, starting at a particular offset, returning the clipped
+ string with ellipses representing the removed parts
+
+ The string to be clipped
+ The maximum permitted length of the result string
+ The point at which to start clipping
+ The clipped string
+
+
+
+ Clip the expected and actual strings in a coordinated fashion,
+ so that they may be displayed together.
+
+
+
+
+
+
+
+
+ Shows the position two strings start to differ. Comparison
+ starts at the start index.
+
+ The expected string
+ The actual string
+ The index in the strings at which comparison should start
+ Boolean indicating whether case should be ignored
+ -1 if no mismatch found, or the index where mismatch found
+
+
+
+ Summary description for SetCultureAttribute.
+
+
+
+
+ PropertyAttribute is used to attach information to a test as a name/value pair..
+
+
+
+
+ The property name
+
+
+
+
+ The property value
+
+
+
+
+ Construct a PropertyAttribute with a name and value
+
+ The name of the property
+ The property value
+
+
+
+ Constructor for use by inherited classes that use the
+ name of the type as the property name.
+
+
+
+
+ Gets the property name
+
+
+
+
+ Gets the property value
+
+
+
+
+ Construct given the name of a culture
+
+
+
+
+
+ TextMessageWriter writes constraint descriptions and messages
+ in displayable form as a text stream. It tailors the display
+ of individual message components to form the standard message
+ format of NUnit assertion failure messages.
+
+
+
+
+ Prefix used for the expected value line of a message
+
+
+
+
+ Prefix used for the actual value line of a message
+
+
+
+
+ Length of a message prefix
+
+
+
+
+ Construct a TextMessageWriter
+
+
+
+
+ Construct a TextMessageWriter, specifying a user message
+ and optional formatting arguments.
+
+
+
+
+
+
+ Method to write single line message with optional args, usually
+ written to precede the general failure message, at a givel
+ indentation level.
+
+ The indentation level of the message
+ The message to be written
+ Any arguments used in formatting the message
+
+
+
+ Display Expected and Actual lines for a constraint. This
+ is called by MessageWriter's default implementation of
+ WriteMessageTo and provides the generic two-line display.
+
+ The constraint that failed
+
+
+
+ Display Expected and Actual lines for given values. This
+ method may be called by constraints that need more control over
+ the display of actual and expected values than is provided
+ by the default implementation.
+
+ The expected value
+ The actual value causing the failure
+
+
+
+ Display Expected and Actual lines for given values, including
+ a tolerance value on the expected line.
+
+ The expected value
+ The actual value causing the failure
+ The tolerance within which the test was made
+
+
+
+ Display the expected and actual string values on separate lines.
+ If the mismatch parameter is >=0, an additional line is displayed
+ line containing a caret that points to the mismatch point.
+
+ The expected string value
+ The actual string value
+ The point at which the strings don't match or -1
+ If true, case is ignored in string comparisons
+ If true, clip the strings to fit the max line length
+
+
+
+ Writes the text for a connector.
+
+ The connector.
+
+
+
+ Writes the text for a predicate.
+
+ The predicate.
+
+
+
+ Write the text for a modifier.
+
+ The modifier.
+
+
+
+ Writes the text for an expected value.
+
+ The expected value.
+
+
+
+ Writes the text for an actual value.
+
+ The actual value.
+
+
+
+ Writes the text for a generalized value.
+
+ The value.
+
+
+
+ Writes the text for a collection value,
+ starting at a particular point, to a max length
+
+ The collection containing elements to write.
+ The starting point of the elements to write
+ The maximum number of elements to write
+
+
+
+ Write the generic 'Expected' line for a constraint
+
+ The constraint that failed
+
+
+
+ Write the generic 'Expected' line for a given value
+
+ The expected value
+
+
+
+ Write the generic 'Expected' line for a given value
+ and tolerance.
+
+ The expected value
+ The tolerance within which the test was made
+
+
+
+ Write the generic 'Actual' line for a constraint
+
+ The constraint for which the actual value is to be written
+
+
+
+ Write the generic 'Actual' line for a given value
+
+ The actual value causing a failure
+
+
+
+ Gets or sets the maximum line length for this writer
+
+
+
+
+ Basic Asserts on strings.
+
+
+
+
+ The Equals method throws an AssertionException. This is done
+ to make sure there is no mistake by calling this function.
+
+
+
+
+
+
+ override the default ReferenceEquals to throw an AssertionException. This
+ implementation makes sure there is no mistake in calling this function
+ as part of Assert.
+
+
+
+
+
+
+ Asserts that a string is found within another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that a string is found within another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that a string is found within another string.
+
+ The expected string
+ The string to be examined
+
+
+
+ Asserts that a string starts with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that a string starts with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that a string starts with another string.
+
+ The expected string
+ The string to be examined
+
+
+
+ Asserts that a string ends with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that a string ends with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that a string ends with another string.
+
+ The expected string
+ The string to be examined
+
+
+
+ Asserts that two strings are equal, without regard to case.
+
+ The expected string
+ The actual string
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that two strings are equal, without regard to case.
+
+ The expected string
+ The actual string
+ The message to display in case of failure
+
+
+
+ Asserts that two strings are equal, without regard to case.
+
+ The expected string
+ The actual string
+
+
+
+ Asserts that a string matches an expected regular expression pattern.
+
+ The expected expression
+ The actual string
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that a string matches an expected regular expression pattern.
+
+ The expected expression
+ The actual string
+ The message to display in case of failure
+
+
+
+ Asserts that a string matches an expected regular expression pattern.
+
+ The expected expression
+ The actual string
+
+
+
+ AssertionHelper is an optional base class for user tests,
+ allowing the use of shorter names for constraints and
+ asserts and avoiding conflict with the definition of
+ , from which it inherits much of its
+ behavior, in certain mock object frameworks.
+
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to
+
+ A Constraint to be applied
+ The actual value to test
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to
+
+ A Constraint to be applied
+ The actual value to test
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to
+
+ A Constraint to be applied
+ The actual value to test
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an . Works Identically to
+ .
+
+ The evaluated condition
+ The message to display if the condition is false
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an . Works Identically to
+ .
+
+ The evaluated condition
+ The message to display if the condition is false
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an . Works Identically to .
+
+ The evaluated condition
+
+
+
+ Returns a ListMapper based on a collection.
+
+ The original collection
+
+
+
+
+ Summary description for FileAssert.
+
+
+
+
+ The Equals method throws an AssertionException. This is done
+ to make sure there is no mistake by calling this function.
+
+
+
+
+
+
+ override the default ReferenceEquals to throw an AssertionException. This
+ implementation makes sure there is no mistake in calling this function
+ as part of Assert.
+
+
+
+
+
+
+ We don't actually want any instances of this object, but some people
+ like to inherit from it to add other static methods. Hence, the
+ protected constructor disallows any instances of this object.
+
+
+
+
+ Verifies that two Streams are equal. Two Streams are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The expected Stream
+ The actual Stream
+ The message to display if Streams are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two Streams are equal. Two Streams are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The expected Stream
+ The actual Stream
+ The message to display if objects are not equal
+
+
+
+ Verifies that two Streams are equal. Two Streams are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The expected Stream
+ The actual Stream
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+ The message to display if Streams are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+ The message to display if objects are not equal
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+ The message to display if Streams are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+ The message to display if objects are not equal
+
+
+
+ Verifies that two files are equal. Two files are considered
+ equal if both are null, or if both have the same value byte for byte.
+ If they are not equal an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+
+
+
+ Asserts that two Streams are not equal. If they are equal
+ an is thrown.
+
+ The expected Stream
+ The actual Stream
+ The message to be displayed when the two Stream are the same.
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two Streams are not equal. If they are equal
+ an is thrown.
+
+ The expected Stream
+ The actual Stream
+ The message to be displayed when the Streams are the same.
+
+
+
+ Asserts that two Streams are not equal. If they are equal
+ an is thrown.
+
+ The expected Stream
+ The actual Stream
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+ The message to display if Streams are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+ The message to display if objects are not equal
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ A file containing the value that is expected
+ A file containing the actual value
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+ The message to display if Streams are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+ The message to display if objects are not equal
+
+
+
+ Asserts that two files are not equal. If they are equal
+ an is thrown.
+
+ The path to a file containing the value that is expected
+ The path to a file containing the actual value
+
+
+
+ Thrown when an assertion failed.
+
+
+
+
+
+
+ The error message that explains
+ the reason for the exception
+ The exception that caused the
+ current exception
+
+
+
+ Serialization Constructor
+
+
+
+
+ GlobalSettings is a place for setting default values used
+ by the framework in performing asserts.
+
+
+
+
+ Default tolerance for floating point equality
+
+
+
+
+ Obsolete class, formerly used to identify tests through
+ inheritance. Avoid using this class for new tests.
+
+
+
+
+ Method called immediately before running the test.
+
+
+
+
+ Method Called immediately after running the test. It is
+ guaranteed to be called, even if an exception is thrown.
+
+
+
+
+ Attribute used to mark a class that contains one-time SetUp
+ and/or TearDown methods that apply to all the tests in a
+ namespace or an assembly.
+
+
+
+
+ SetUpFixtureAttribute is used to identify a SetUpFixture
+
+
+
+
+ Attribute used to mark a static (shared in VB) property
+ that returns a list of tests.
+
+
+
+
+ Attribute used to identify a method that is called
+ immediately after each test is run. The method is
+ guaranteed to be called, even if an exception is thrown.
+
+
+
+
+ Adding this attribute to a method within a
+ class makes the method callable from the NUnit test runner. There is a property
+ called Description which is optional which you can provide a more detailed test
+ description. This class cannot be inherited.
+
+
+
+ [TestFixture]
+ public class Fixture
+ {
+ [Test]
+ public void MethodToTest()
+ {}
+
+ [Test(Description = "more detailed description")]
+ publc void TestDescriptionMethod()
+ {}
+ }
+
+
+
+
+
+ Descriptive text for this test
+
+
+
+
+ [TestFixture]
+ public class ExampleClass
+ {}
+
+
+
+
+ Descriptive text for this fixture
+
+
+
+
+ Attribute used to identify a method that is
+ called before any tests in a fixture are run.
+
+
+
+
+ Attribute used to identify a method that is called after
+ all the tests in a fixture have run. The method is
+ guaranteed to be called, even if an exception is thrown.
+
+
+
+
+ Attribute used to mark a test that is to be ignored.
+ Ignored tests result in a warning message when the
+ tests are run.
+
+
+
+
+ Constructs the attribute without giving a reason
+ for ignoring the test.
+
+
+
+
+ Constructs the attribute giving a reason for ignoring the test
+
+ The reason for ignoring the test
+
+
+
+ The reason for ignoring a test
+
+
+
+
+ ExplicitAttribute marks a test or test fixture so that it will
+ only be run if explicitly executed from the gui or command line
+ or if it is included by use of a filter. The test will not be
+ run simply because an enclosing suite is run.
+
+
+
+
+ Default constructor
+
+
+
+
+ Constructor with a reason
+
+ The reason test is marked explicit
+
+
+
+ The reason test is marked explicit
+
+
+
+
+ Attribute used to provide descriptive text about a
+ test case or fixture.
+
+
+
+
+ Construct the attribute
+
+ Text describing the test
+
+
+
+ Gets the test description
+
+
+
+
+ Interface implemented by a user fixture in order to
+ validate any expected exceptions. It is only called
+ for test methods marked with the ExpectedException
+ attribute.
+
+
+
+
+ Method to handle an expected exception
+
+ The exception to be handled
+
+
+
diff --git a/09-NoSQL/CrashCourse/Client/ServiceProxy.cs b/09-NoSQL/CrashCourse/Client/ServiceProxy.cs
deleted file mode 100644
index d509af9..0000000
--- a/09-NoSQL/CrashCourse/Client/ServiceProxy.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-using System.Net;
-using Client.Parameters;
-using GroboContainer.Core;
-using SKBKontur.WebPersonal.Core.Networking.ClientSide.Http;
-using SKBKontur.WebPersonal.Core.Serialization;
-using SKBKontur.WebPersonal.Core.Common;
-
-namespace Client
-{
- public class ServiceProxy : IServiceProxy
- {
- private readonly IIpRemoteHttpServer remoteHttpServer;
- private readonly IGroboSerializer groboSerializer;
-
- public ServiceProxy(IPEndPoint endPoint, IGroboSerializer groboSerializer, IContainer container)
- {
- remoteHttpServer = container.Create(endPoint, 1000);
- this.groboSerializer = groboSerializer;
- }
-
- #region IPrintServiceProxy Members
-
- #endregion
-
- public void Write(string key, Data value)
- {
- IHttpRequest request = remoteHttpServer.CreatePostRequest("Write");
- request.BodyStream.WriteBytes(groboSerializer.Serialize(new WriteParameters{Key = key, Value = value}));
- request.SendOrDie();
- }
-
- public Data Read(string key)
- {
- IHttpRequest request = remoteHttpServer.CreateGetRequest("Read");
- request.BodyStream.WriteBytes(groboSerializer.Serialize(new ReadParameters{Key = key}));
- var response = request.SendOrDie();
- return groboSerializer.Deserialize(response.BodyStream.ReadToEnd());
- }
- }
-}
diff --git a/09-NoSQL/CrashCourse/CrashCourse.sln b/09-NoSQL/CrashCourse/CrashCourse.sln
index 8fe246b..37fb9c5 100644
--- a/09-NoSQL/CrashCourse/CrashCourse.sln
+++ b/09-NoSQL/CrashCourse/CrashCourse.sln
@@ -5,6 +5,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Service", "Service\Service.
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Client", "Client\Client.csproj", "{7B9907D3-D0F4-4566-96E8-3E3859ABF08E}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tests", "Tests\Tests.csproj", "{5E9DEBC1-7FDF-4455-9D9E-645661258649}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HighLevelClient", "HighLevelClient\HighLevelClient.csproj", "{057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -19,6 +23,14 @@ Global
{7B9907D3-D0F4-4566-96E8-3E3859ABF08E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7B9907D3-D0F4-4566-96E8-3E3859ABF08E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7B9907D3-D0F4-4566-96E8-3E3859ABF08E}.Release|Any CPU.Build.0 = Release|Any CPU
+ {5E9DEBC1-7FDF-4455-9D9E-645661258649}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {5E9DEBC1-7FDF-4455-9D9E-645661258649}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {5E9DEBC1-7FDF-4455-9D9E-645661258649}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {5E9DEBC1-7FDF-4455-9D9E-645661258649}.Release|Any CPU.Build.0 = Release|Any CPU
+ {057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/09-NoSQL/CrashCourse/HighLevelClient/EnterpriseClient.cs b/09-NoSQL/CrashCourse/HighLevelClient/EnterpriseClient.cs
new file mode 100644
index 0000000..1e3364f
--- /dev/null
+++ b/09-NoSQL/CrashCourse/HighLevelClient/EnterpriseClient.cs
@@ -0,0 +1,37 @@
+using System;
+using System.Net;
+using Client;
+using Client.Parameters;
+
+namespace HighLevelClient
+{
+ public class EnterpriseClient
+ {
+ private static readonly Random random = new Random();
+ private readonly IPEndPoint[] endpoints;
+ private readonly ServiceClient internalClient;
+
+ public EnterpriseClient(IPEndPoint[] endpoints)
+ {
+ this.endpoints = endpoints;
+ internalClient = new ServiceClient();
+ }
+
+ private IPEndPoint NextReplica
+ {
+ get { return endpoints[random.Next(endpoints.Length)]; }
+ }
+
+ public void Write(string key, string value)
+ {
+ Data data = internalClient.Read(key, NextReplica) ?? new Data();
+ internalClient.Write(key, new Data { Value = value, Version = data.Version + 1 }, NextReplica);
+ }
+
+ public string Read(string key)
+ {
+ Data read = internalClient.Read(key, NextReplica);
+ return read == null ? null : read.Value;
+ }
+ }
+}
\ No newline at end of file
diff --git a/09-NoSQL/CrashCourse/HighLevelClient/HighLevelClient.csproj b/09-NoSQL/CrashCourse/HighLevelClient/HighLevelClient.csproj
new file mode 100644
index 0000000..006a9bc
--- /dev/null
+++ b/09-NoSQL/CrashCourse/HighLevelClient/HighLevelClient.csproj
@@ -0,0 +1,59 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {057BA9C0-E56D-4A74-BED2-7A0AF447E4E3}
+ Library
+ Properties
+ HighLevelClient
+ HighLevelClient
+ v4.5
+ 512
+
+
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {7b9907d3-d0f4-4566-96e8-3e3859abf08e}
+ Client
+
+
+
+
+
\ No newline at end of file
diff --git a/09-NoSQL/CrashCourse/HighLevelClient/Properties/AssemblyInfo.cs b/09-NoSQL/CrashCourse/HighLevelClient/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..98dc87b
--- /dev/null
+++ b/09-NoSQL/CrashCourse/HighLevelClient/Properties/AssemblyInfo.cs
@@ -0,0 +1,36 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("HighLevelClient")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("HighLevelClient")]
+[assembly: AssemblyCopyright("Copyright © 2014")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("72dd8122-885e-4306-938f-de6ad4e1f8e7")]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/09-NoSQL/CrashCourse/Service/Http/ReadHttpMethod.cs b/09-NoSQL/CrashCourse/Service/Http/ReadHttpMethod.cs
index a43af0d..e9e554c 100644
--- a/09-NoSQL/CrashCourse/Service/Http/ReadHttpMethod.cs
+++ b/09-NoSQL/CrashCourse/Service/Http/ReadHttpMethod.cs
@@ -9,21 +9,21 @@ namespace Service.Http
public class ReadHttpMethod : IHttpMethod
{
private readonly Disk disk;
- private readonly IGroboSerializer groboSerializer;
+ private readonly IJsonSerializer jsonSerializer;
- public ReadHttpMethod(Disk disk, IGroboSerializer groboSerializer)
+ public ReadHttpMethod(Disk disk, IJsonSerializer jsonSerializer)
{
this.disk = disk;
- this.groboSerializer = groboSerializer;
+ this.jsonSerializer = jsonSerializer;
}
#region IHttpMethod Members
public void Process(HttpContext context)
{
- var readParameters = groboSerializer.Deserialize(context.Request.Body);
+ var readParameters = jsonSerializer.Deserialize(context.Request.Body);
var result = disk.Read(readParameters.Key);
- context.Response.BodyStream.WriteBytes(groboSerializer.Serialize(result));
+ context.Response.BodyStream.WriteBytes(jsonSerializer.Serialize(result));
}
#endregion
diff --git a/09-NoSQL/CrashCourse/Service/Http/WriteHttpMethod.cs b/09-NoSQL/CrashCourse/Service/Http/WriteHttpMethod.cs
index 2156a6f..a0d565d 100644
--- a/09-NoSQL/CrashCourse/Service/Http/WriteHttpMethod.cs
+++ b/09-NoSQL/CrashCourse/Service/Http/WriteHttpMethod.cs
@@ -1,5 +1,4 @@
using Client.Parameters;
-using GroBuf;
using SKBKontur.WebPersonal.Core.Networking.ServerSide.Http;
using SKBKontur.WebPersonal.Core.Serialization;
using Service.Infrastructure;
@@ -9,13 +8,13 @@ namespace Service.Http
public class WriteHttpMethod : IHttpMethod
{
private readonly Disk disk;
- private readonly IGroboSerializer groboSerializer;
+ private readonly IJsonSerializer jsonSerializer;
private readonly Replicator replicator;
- public WriteHttpMethod(Disk disk, IGroboSerializer groboSerializer, Replicator replicator)
+ public WriteHttpMethod(Disk disk, IJsonSerializer jsonSerializer, Replicator replicator)
{
this.disk = disk;
- this.groboSerializer = groboSerializer;
+ this.jsonSerializer = jsonSerializer;
this.replicator = replicator;
}
@@ -23,9 +22,9 @@ public WriteHttpMethod(Disk disk, IGroboSerializer groboSerializer, Replicator r
public void Process(HttpContext context)
{
- var writeParameters = groboSerializer.Deserialize(context.Request.Body);
- disk.Write(writeParameters.Key, writeParameters.Value);
- replicator.Replicate(writeParameters.Key, writeParameters.Value);
+ var writeParameters = jsonSerializer.Deserialize(context.Request.Body);
+ if (disk.Write(writeParameters.Key, writeParameters.Value))
+ replicator.Replicate(writeParameters.Key, writeParameters.Value);
}
#endregion
diff --git a/09-NoSQL/CrashCourse/Service/Infrastructure/Disk.cs b/09-NoSQL/CrashCourse/Service/Infrastructure/Disk.cs
index 694225c..79a9d97 100644
--- a/09-NoSQL/CrashCourse/Service/Infrastructure/Disk.cs
+++ b/09-NoSQL/CrashCourse/Service/Infrastructure/Disk.cs
@@ -1,10 +1,5 @@
using System.Collections.Generic;
-using System.Net;
-using System.Threading;
-using System.Threading.Tasks;
-using Client;
using Client.Parameters;
-using SKBKontur.WebPersonal.Core.ApplicationCommon;
namespace Service.Infrastructure
{
@@ -25,39 +20,17 @@ public Data Read(string key)
}
}
- public void Write(string key, Data value)
+ public bool Write(string key, Data value)
{
lock (storage)
{
- if (storage.ContainsKey(key) && value.CompareTo(storage[key]) > 0)
+ if (!storage.ContainsKey(key) || value.CompareTo(storage[key]) > 0)
+ {
storage[key] = value;
+ return true;
+ }
}
- }
- }
-
- public class Replicator
- {
- private readonly IServiceClient serviceClient;
- private readonly IPEndPoint[] endpoints;
-
- public Replicator(IServiceClient serviceClient, IApplicationSettings applicationSettings)
- {
- endpoints = applicationSettings.GetIPEndpointsArray("endpoints");
- this.serviceClient = serviceClient;
- }
-
- public void Replicate(string key, Data value)
- {
- Task.Run(() => ReplicateInternal(key, value));
- }
-
- private void ReplicateInternal(string key, Data value)
- {
- foreach (var endPoint in endpoints)
- {
- Thread.Sleep(5000);
- serviceClient.Write(key, value, endPoint);
- }
+ return false;
}
}
}
\ No newline at end of file
diff --git a/09-NoSQL/CrashCourse/Service/Infrastructure/Replicator.cs b/09-NoSQL/CrashCourse/Service/Infrastructure/Replicator.cs
new file mode 100644
index 0000000..08e1dfb
--- /dev/null
+++ b/09-NoSQL/CrashCourse/Service/Infrastructure/Replicator.cs
@@ -0,0 +1,53 @@
+using System;
+using System.Net;
+using System.Threading;
+using System.Threading.Tasks;
+using Client;
+using Client.Parameters;
+using SKBKontur.WebPersonal.Core.ApplicationCommon;
+using log4net;
+
+namespace Service.Infrastructure
+{
+ public class Replicator
+ {
+ private readonly IServiceClient serviceClient;
+ private readonly IPEndPoint[] endpoints;
+ private static ILog log = LogManager.GetLogger(typeof (Replicator));
+
+ public Replicator(IServiceClient serviceClient, IApplicationSettings applicationSettings)
+ {
+ endpoints = applicationSettings.GetIPEndpointsArray("endpoints");
+ this.serviceClient = serviceClient;
+ }
+
+ public void Replicate(string key, Data value)
+ {
+ Task.Run(() => ReplicateInternal(key, value));
+ }
+
+ private void ReplicateInternal(string key, Data value)
+ {
+ foreach (var endPoint in endpoints)
+ WriteToSingleReplica(key, value, endPoint);
+ }
+
+ private void WriteToSingleReplica(string key, Data value, IPEndPoint endPoint)
+ {
+ log.InfoFormat("Write '{1}':'{2}',{3} to {0}", endPoint, key, value.Value, value.Version);
+ Task.Delay(5000).ContinueWith(t =>
+ {
+ try
+ {
+ serviceClient.Write(key, value, endPoint);
+ log.InfoFormat("Write success '{1}':'{2}',{3} to {0}", endPoint, key, value.Value, value.Version);
+ }
+ catch (Exception)
+ {
+ log.WarnFormat("Write error '{1}':'{2}',{3} to {0}", endPoint, key, value.Value, value.Version);
+ WriteToSingleReplica(key, value, endPoint);
+ }
+ });
+ }
+ }
+}
\ No newline at end of file
diff --git a/09-NoSQL/CrashCourse/Service/Service.csproj b/09-NoSQL/CrashCourse/Service/Service.csproj
index 6ed0b28..380213e 100644
--- a/09-NoSQL/CrashCourse/Service/Service.csproj
+++ b/09-NoSQL/CrashCourse/Service/Service.csproj
@@ -32,11 +32,14 @@
4
+
+ ..\..\Assemblies\GrEmit.dll
+
..\..\Assemblies\GroboContainer.dll
-
- ..\..\Assemblies\GroBuf.dll
+
+ ..\..\Assemblies\log4net.dll
@@ -55,12 +58,17 @@
+
-
-
+
+ Always
+
+
+ Always
+
diff --git a/09-NoSQL/CrashCourse/Service/Settings/serviceSettings b/09-NoSQL/CrashCourse/Service/Settings/serviceSettings
index eec04e2..ba5d000 100644
--- a/09-NoSQL/CrashCourse/Service/Settings/serviceSettings
+++ b/09-NoSQL/CrashCourse/Service/Settings/serviceSettings
@@ -18,3 +18,5 @@ serviceName = print
# Ïðèçíàê òîãî, ÷òî ñåðâèñ çàïóñêàåòñÿ â îòëàäî÷íîì ðåæèìå
debug = true
+
+endpoints =
diff --git a/09-NoSQL/CrashCourse/Tests/Properties/AssemblyInfo.cs b/09-NoSQL/CrashCourse/Tests/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..bbf38d1
--- /dev/null
+++ b/09-NoSQL/CrashCourse/Tests/Properties/AssemblyInfo.cs
@@ -0,0 +1,36 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("Tests")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("Tests")]
+[assembly: AssemblyCopyright("Copyright © 2014")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("6d9070ee-8472-4c76-a994-137f15f77f36")]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/09-NoSQL/CrashCourse/Tests/Test.cs b/09-NoSQL/CrashCourse/Tests/Test.cs
new file mode 100644
index 0000000..c2380a6
--- /dev/null
+++ b/09-NoSQL/CrashCourse/Tests/Test.cs
@@ -0,0 +1,55 @@
+using System;
+using System.Net;
+using System.Threading;
+using Client;
+using Client.Parameters;
+using NUnit.Framework;
+
+namespace Tests
+{
+ [TestFixture]
+ public class Test
+ {
+ private ServiceClient client;
+ private IPEndPoint ipEndPoint1;
+ private IPEndPoint ipEndPoint2;
+
+ [SetUp]
+ public void SetUp()
+ {
+ client = new ServiceClient();
+ ipEndPoint1 = new IPEndPoint(new IPAddress(new byte[] { 127, 0, 0, 1 }), 5088);
+ ipEndPoint2 = new IPEndPoint(new IPAddress(new byte[] { 127, 0, 0, 1 }), 5086);
+ }
+
+ [Test]
+ public void Xxx()
+ {
+ client.Write("x", new Data{Value = "y", Version = 1}, ipEndPoint1);
+ var res = client.Read("x", ipEndPoint1);
+ Assert.AreEqual("y", res.Value);
+ res = client.Read("x", ipEndPoint2);
+ Assert.IsNull(res);
+ Thread.Sleep(11000);
+ res = client.Read("x", ipEndPoint2);
+ Assert.AreEqual("y", res.Value);
+ }
+
+ [Test]
+ public void Qqq()
+ {
+ client.Write("a", new Data {Value = "b", Version = 3}, ipEndPoint1);
+ var value = client.Read("a", ipEndPoint1);
+ Console.Out.WriteLine(value.Version);
+
+ Thread.Sleep(20000);
+ Console.Out.WriteLine("Start!!!!");
+
+ Console.Out.WriteLine("Sleep 60");
+ Thread.Sleep(60000);
+
+ var anotherValue = client.Read("a", ipEndPoint2);
+ Console.Out.WriteLine(anotherValue.Version);
+ }
+ }
+}
diff --git a/09-NoSQL/CrashCourse/Tests/Tests.csproj b/09-NoSQL/CrashCourse/Tests/Tests.csproj
new file mode 100644
index 0000000..4055553
--- /dev/null
+++ b/09-NoSQL/CrashCourse/Tests/Tests.csproj
@@ -0,0 +1,63 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {5E9DEBC1-7FDF-4455-9D9E-645661258649}
+ Library
+ Properties
+ Tests
+ Tests
+ v4.5
+ 512
+
+
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+ False
+ ..\..\Assemblies\nunit.framework.dll
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {7b9907d3-d0f4-4566-96e8-3e3859abf08e}
+ Client
+
+
+
+
+
\ No newline at end of file
diff --git a/09-NoSQL/CrashCourse/Client/Client.csproj b/09-nosql/crashcourse/Client/Client.csproj
similarity index 96%
rename from 09-NoSQL/CrashCourse/Client/Client.csproj
rename to 09-nosql/crashcourse/Client/Client.csproj
index 082e541..437f08f 100644
--- a/09-NoSQL/CrashCourse/Client/Client.csproj
+++ b/09-nosql/crashcourse/Client/Client.csproj
@@ -33,9 +33,6 @@
..\..\Assemblies\GroboContainer.dll
-
- ..\..\Assemblies\GroBuf.dll
-
diff --git a/09-NoSQL/CrashCourse/Client/IServiceClient.cs b/09-nosql/crashcourse/Client/IServiceClient.cs
similarity index 100%
rename from 09-NoSQL/CrashCourse/Client/IServiceClient.cs
rename to 09-nosql/crashcourse/Client/IServiceClient.cs
diff --git a/09-NoSQL/CrashCourse/Client/IServiceProxy.cs b/09-nosql/crashcourse/Client/IServiceProxy.cs
similarity index 100%
rename from 09-NoSQL/CrashCourse/Client/IServiceProxy.cs
rename to 09-nosql/crashcourse/Client/IServiceProxy.cs
diff --git a/09-NoSQL/CrashCourse/Client/Parameters/ReadParameters.cs b/09-nosql/crashcourse/Client/Parameters/ReadParameters.cs
similarity index 100%
rename from 09-NoSQL/CrashCourse/Client/Parameters/ReadParameters.cs
rename to 09-nosql/crashcourse/Client/Parameters/ReadParameters.cs
diff --git a/09-NoSQL/CrashCourse/Client/Parameters/WriteParameters.cs b/09-nosql/crashcourse/Client/Parameters/WriteParameters.cs
similarity index 100%
rename from 09-NoSQL/CrashCourse/Client/Parameters/WriteParameters.cs
rename to 09-nosql/crashcourse/Client/Parameters/WriteParameters.cs
diff --git a/09-NoSQL/CrashCourse/Client/Properties/AssemblyInfo.cs b/09-nosql/crashcourse/Client/Properties/AssemblyInfo.cs
similarity index 100%
rename from 09-NoSQL/CrashCourse/Client/Properties/AssemblyInfo.cs
rename to 09-nosql/crashcourse/Client/Properties/AssemblyInfo.cs
diff --git a/09-NoSQL/CrashCourse/Client/ServiceClient.cs b/09-nosql/crashcourse/Client/ServiceClient.cs
similarity index 69%
rename from 09-NoSQL/CrashCourse/Client/ServiceClient.cs
rename to 09-nosql/crashcourse/Client/ServiceClient.cs
index c483b2f..0cc1b27 100644
--- a/09-NoSQL/CrashCourse/Client/ServiceClient.cs
+++ b/09-nosql/crashcourse/Client/ServiceClient.cs
@@ -1,6 +1,7 @@
using System;
using System.Net;
using Client.Parameters;
+using SKBKontur.WebPersonal.Core.Serialization;
namespace Client
{
@@ -8,9 +9,11 @@ public class ServiceClient : IServiceClient
{
private readonly Func createProxy;
- public ServiceClient(Func createProxy)
+
+ public ServiceClient()
{
- this.createProxy = createProxy;
+ var jsonSerializer = new JsonSerializer();
+ createProxy = ipEndPoint => new ServiceProxy(ipEndPoint, jsonSerializer);
}
public void Write(string key, Data value, IPEndPoint endPoint)
diff --git a/09-nosql/crashcourse/Client/ServiceProxy.cs b/09-nosql/crashcourse/Client/ServiceProxy.cs
new file mode 100644
index 0000000..66f7562
--- /dev/null
+++ b/09-nosql/crashcourse/Client/ServiceProxy.cs
@@ -0,0 +1,39 @@
+using System.Net;
+using Client.Parameters;
+using SKBKontur.WebPersonal.Core.Logging.RequestLoggers;
+using SKBKontur.WebPersonal.Core.Networking.ClientSide.Http;
+using SKBKontur.WebPersonal.Core.Networking.ServerSide.Http;
+using SKBKontur.WebPersonal.Core.Serialization;
+using SKBKontur.WebPersonal.Core.Common;
+using IHttpRequest = SKBKontur.WebPersonal.Core.Networking.ClientSide.Http.IHttpRequest;
+
+namespace Client
+{
+ public class ServiceProxy : IServiceProxy
+ {
+ private readonly IJsonSerializer jsonSerializer;
+ private readonly IIpRemoteHttpServer remoteHttpServer;
+
+ public ServiceProxy(IPEndPoint endPoint, IJsonSerializer jsonSerializer)
+ {
+ this.jsonSerializer = jsonSerializer;
+ var requestTracker = new RequestTracker(new GuidFactory());
+ remoteHttpServer = new IpRemoteHttpServerWithLogger(endPoint, 1000, requestTracker, new OuterHttpMethodsLogger(requestTracker));
+ }
+
+ public void Write(string key, Data value)
+ {
+ IHttpRequest request = remoteHttpServer.CreatePostRequest("Write");
+ request.BodyStream.WriteBytes(jsonSerializer.Serialize(new WriteParameters { Key = key, Value = value }));
+ request.SendOrDie();
+ }
+
+ public Data Read(string key)
+ {
+ IHttpRequest request = remoteHttpServer.CreatePostRequest("Read");
+ request.BodyStream.WriteBytes(jsonSerializer.Serialize(new ReadParameters { Key = key }));
+ var response = request.SendOrDie();
+ return jsonSerializer.Deserialize(response.BodyStream.ReadToEnd());
+ }
+ }
+}