diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..412eeda
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,22 @@
+# Auto detect text files and perform LF normalization
+* text=auto
+
+# Custom for Visual Studio
+*.cs diff=csharp
+*.sln merge=union
+*.csproj merge=union
+*.vbproj merge=union
+*.fsproj merge=union
+*.dbproj merge=union
+
+# Standard to msysgit
+*.doc diff=astextplain
+*.DOC diff=astextplain
+*.docx diff=astextplain
+*.DOCX diff=astextplain
+*.dot diff=astextplain
+*.DOT diff=astextplain
+*.pdf diff=astextplain
+*.PDF diff=astextplain
+*.rtf diff=astextplain
+*.RTF diff=astextplain
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..7356abc
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,10 @@
+*.svn
+[Bb]in
+[Oo]bj
+*ReSharper*
+*resharper*
+*.user
+*.suo
+*.sqlsuo
+*.pdb
+*.rdl.data
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..ff3bd4a
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,28 @@
+Copyright (c) 2001-2004, Stephen Hebert
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+
+Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the distribution.
+
+Neither the name of the .Math, nor the names of its contributors
+may be used to endorse or promote products derived from this software without
+specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
+OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/README.md b/README.md
index 27fb533..528f555 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,28 @@
-dotMath
-=======
+dotMath
+==================================================
-Fork of the dotMath library by Stephen Hebert
+This is a fork of the [dotMath](http://dotmath.codeplex.com/) library by Stephen Hebert, currently hosted on CodePlex, which hasn't been updated since 2004. The documentation found here and on the wiki is mostly pulled from the CodePlex site.
+
+Overview
+--------------------------------------------------
+
+Welcome to dotMath, the extensible open source expression compiler for the .NET platform written entirely in C#. Offering speed through compilation of expressions, the library allows for variable handling, an entire function library and the ability to add your own functions.
+
+If you need to evaluate fixed or variable expressions, dotMath is your solution:
+
+**Fixed expression example:**
+
+ (sin(5)* cos(4/5)) / 3
+
+**Variable expression example:**
+
+ (sin(a)* cos(b/a)) / c
+
+_If you're only interested in downloading the binary, you can find the 1.0 release on [CodePlex](http://dotmath.codeplex.com/releases/view/875)._
+
+Documentation
+--------------------------------------------------
+
+[Getting Started - How to use dotMath]()
+
+[Built-in functions and operators]()
\ No newline at end of file
diff --git a/Tests/Properties/AssemblyInfo.cs b/Tests/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..449512c
--- /dev/null
+++ b/Tests/Properties/AssemblyInfo.cs
@@ -0,0 +1,34 @@
+using System.Reflection;
+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("dotMath Unit Tests")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Steve Hebert and Hebert Software Services, LLC")]
+[assembly: AssemblyProduct("dotMath.Tests")]
+[assembly: AssemblyCopyright("Copyright 2001-2004")]
+[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("B5404ADB-641F-4B3D-A04D-265962BF11B2")]
+
+// 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/Tests/StaticOutputTests.cs b/Tests/StaticOutputTests.cs
new file mode 100644
index 0000000..789a19d
--- /dev/null
+++ b/Tests/StaticOutputTests.cs
@@ -0,0 +1,365 @@
+using System;
+using System.Text;
+using NUnit.Framework;
+
+namespace dotMath.Tests
+{
+ [TestFixture]
+ public class StaticOutputTests
+ {
+ private double m_a;
+ private double m_b;
+ private double m_c;
+ private double m_d;
+
+ private EqCompiler GetCompilerSetup(string sFunction)
+ {
+ m_a = -4;
+ m_b = 4;
+ m_c = -8;
+ m_d = -8;
+
+ EqCompiler oComp = new EqCompiler(sFunction, true);
+ oComp.SetVariable("a", m_a);
+ oComp.SetVariable("b", m_b);
+ oComp.SetVariable("c", m_c);
+ oComp.SetVariable("d", m_d);
+
+ return oComp;
+ }
+
+ [Test]
+ public void ConstantExpression()
+ {
+ EqCompiler oComp = GetCompilerSetup("a");
+
+ Assert.AreEqual(m_a, oComp.Calculate());
+ }
+
+
+ [Test]
+ public void SignNeg()
+ {
+ EqCompiler oComp = new EqCompiler("-4.2", false);
+
+ Assert.AreEqual(-4.2, oComp.Calculate());
+ }
+
+ [Test]
+ public void DivideByZero()
+ {
+ EqCompiler oComp = new EqCompiler("4/0", false);
+
+ double dValue1 = 4;
+ double dValue2 = 0;
+ double dValue = dValue1 / dValue2;
+ Assert.AreEqual(dValue, oComp.Calculate());
+ }
+
+ [Test]
+ public void Addition()
+ {
+ EqCompiler oComp = new EqCompiler("2+2", false);
+
+ Assert.AreEqual(2 + 2, oComp.Calculate());
+ }
+
+ [Test]
+ public void Multiplication()
+ {
+ EqCompiler oComp = new EqCompiler("4*4", false);
+
+ Assert.AreEqual(4 * 4, oComp.Calculate());
+ }
+
+ [Test]
+ public void Division()
+ {
+ EqCompiler oComp = new EqCompiler("16/2", false);
+
+ Assert.AreEqual(16 / 2, oComp.Calculate());
+ }
+
+ [Test]
+ public void Subtraction()
+ {
+ EqCompiler oComp = new EqCompiler("10-2", false);
+
+ Assert.AreEqual(10 - 2, oComp.Calculate());
+ }
+
+ [Test]
+ public void Exponent()
+ {
+ EqCompiler oComp = new EqCompiler("8^2", false);
+
+ Assert.AreEqual(Math.Pow(8, 2), oComp.Calculate());
+ }
+
+ [Test]
+ public void MultipleFunctionsPerObject()
+ {
+ EqCompiler oComp = new EqCompiler("abs(-4)", true);
+ Assert.AreEqual(Math.Abs(-4), oComp.Calculate());
+
+ oComp.SetFunction("acos(10)");
+ Assert.AreEqual(Math.Acos(10), oComp.Calculate());
+ }
+
+ [Test]
+ public void NestedFunctions()
+ {
+ EqCompiler oComp = new EqCompiler("sin(cos(tan(4.2)))", true);
+
+ Assert.AreEqual(Math.Sin(Math.Cos(Math.Tan(4.2))), oComp.Calculate());
+ }
+
+ [Test]
+ public void Abs()
+ {
+ EqCompiler oComp = new EqCompiler("abs(-5)", true);
+
+ Assert.AreEqual(Math.Abs(-5), oComp.Calculate());
+ }
+
+ [Test]
+ public void Acos()
+ {
+ EqCompiler oComp = new EqCompiler("acos(4)", true);
+
+ Assert.AreEqual(Math.Acos(4), oComp.Calculate());
+ }
+
+ [Test]
+ public void Asin()
+ {
+ EqCompiler oComp = new EqCompiler("asin(4)", true);
+
+ Assert.AreEqual(Math.Asin(4), oComp.Calculate());
+ }
+
+ [Test]
+ public void Atan()
+ {
+ EqCompiler oComp = new EqCompiler("atan(4)", true);
+
+ Assert.AreEqual(Math.Atan(4), oComp.Calculate());
+ }
+
+ [Test]
+ public void Ceiling()
+ {
+ EqCompiler oComp = new EqCompiler("ceiling(-3.2)", true);
+
+ Assert.AreEqual(Math.Ceiling(-3.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Cos()
+ {
+ EqCompiler oComp = new EqCompiler("cos(4)", true);
+
+ Assert.AreEqual(Math.Cos(4), oComp.Calculate());
+ }
+
+ [Test]
+ public void Cosh()
+ {
+ EqCompiler oComp = new EqCompiler("cosh(4)", true);
+
+ Assert.AreEqual(Math.Cosh(4), oComp.Calculate());
+ }
+
+ [Test]
+ public void Exp()
+ {
+ EqCompiler oComp = new EqCompiler("exp(4.2)", true);
+
+ Assert.AreEqual(Math.Exp(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Floor()
+ {
+ EqCompiler oComp = new EqCompiler("floor(-4.2)", true);
+
+ Assert.AreEqual(Math.Floor(-4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Log()
+ {
+ EqCompiler oComp = new EqCompiler("log(4.2)", true);
+
+ Assert.AreEqual(Math.Log(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Log10()
+ {
+ EqCompiler oComp = new EqCompiler("log10(4.2)", true);
+
+ Assert.AreEqual(Math.Log10(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Round()
+ {
+ EqCompiler oComp = new EqCompiler("round(4.2)", true);
+
+ Assert.AreEqual(Math.Round(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sign()
+ {
+ EqCompiler oComp = new EqCompiler("sign(-4.2)", true);
+
+ Assert.AreEqual(Math.Sign(-4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sin()
+ {
+ EqCompiler oComp = new EqCompiler("sin(4.2)", true);
+
+ Assert.AreEqual(Math.Sin(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sinh()
+ {
+ EqCompiler oComp = new EqCompiler("sinh(4.2)", true);
+
+ Assert.AreEqual(Math.Sinh(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sqrt()
+ {
+ EqCompiler oComp = new EqCompiler("sqrt(4.2)", true);
+
+ Assert.AreEqual(Math.Sqrt(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Tan()
+ {
+ EqCompiler oComp = new EqCompiler("tan(4.2)", true);
+
+ Assert.AreEqual(Math.Tan(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Tanh()
+ {
+ EqCompiler oComp = new EqCompiler("tanh(4.2)", true);
+
+ Assert.AreEqual(Math.Tanh(4.2), oComp.Calculate());
+ }
+
+ [Test]
+ public void Max_ExtremeTest()
+ {
+ StringBuilder sMax = new StringBuilder("max( 3,2,5,4", 300000); //actual needed space is 288903
+
+ for (int i = 0; i < 50000; i++)
+ sMax.AppendFormat(",{0}", i);
+
+ sMax.Append(")");
+
+ EqCompiler oComp = new EqCompiler(sMax.ToString(), true);
+
+ Assert.AreEqual(49999, oComp.Calculate());
+ }
+
+ [Test]
+ public void Max()
+ {
+ EqCompiler oComp = new EqCompiler("max(3,2,5,4)", true);
+
+ Assert.AreEqual(5, oComp.Calculate());
+ }
+
+ [Test]
+ public void Min_ExtremeTest()
+ {
+ StringBuilder sMin = new StringBuilder("min(3,2,5,4", 300000); //actual needed space is 288903
+
+ for (int i = 0; i < 50000; i++)
+ sMin.Append(string.Format(",{0}", i));
+
+ sMin.Append(")");
+
+ EqCompiler oComp = new EqCompiler(sMin.ToString(), true);
+
+ Assert.AreEqual(0, oComp.Calculate());
+ }
+
+ [Test]
+ public void Min()
+ {
+ EqCompiler oComp = new EqCompiler("min(3,2,5,4)", true);
+
+ Assert.AreEqual(2, oComp.Calculate());
+ }
+
+ [Test]
+ public void IfThen()
+ {
+ EqCompiler oComp = new EqCompiler("if(1<2,3,4)", true);
+
+ Assert.AreEqual(3, oComp.Calculate());
+ }
+
+ [Test]
+ public void IfElse()
+ {
+ EqCompiler oComp = new EqCompiler("if(2<1,3,4)", true);
+
+ Assert.AreEqual(4, oComp.Calculate());
+ }
+
+ [Test]
+ public void BinaryOperators()
+ {
+ EqCompiler oComp = new EqCompiler(true);
+
+ oComp.SetFunction("1<2");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("1<=2");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("2>1");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("2>=1");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("2==2");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("2<1");
+ Assert.AreEqual(0, oComp.Calculate());
+
+ oComp.SetFunction("2<=1");
+ Assert.AreEqual(0, oComp.Calculate());
+
+ oComp.SetFunction("1>2");
+ Assert.AreEqual(0, oComp.Calculate());
+
+ oComp.SetFunction("1>=2");
+ Assert.AreEqual(0, oComp.Calculate());
+
+ oComp.SetFunction("2==1");
+ Assert.AreEqual(0, oComp.Calculate());
+
+ oComp.SetFunction("2>=2");
+ Assert.AreEqual(1, oComp.Calculate());
+
+ oComp.SetFunction("2<=2");
+ Assert.AreEqual(1, oComp.Calculate());
+ }
+ }
+}
diff --git a/Tests/Tests.csproj b/Tests/Tests.csproj
new file mode 100644
index 0000000..3817033
--- /dev/null
+++ b/Tests/Tests.csproj
@@ -0,0 +1,129 @@
+
+
+
+ Local
+ 7.0.9466
+ 1.0
+ {1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}
+ Debug
+ AnyCPU
+
+
+ dotMath.Tests
+
+ JScript
+ Grid
+ IE50
+ false
+ Library
+ dotMath.Tests
+
+
+
+ v2.0
+
+
+ 0.0
+ publish\
+ true
+ Disk
+ false
+ Foreground
+ 7
+ Days
+ false
+ false
+ true
+ 0
+ 1.0.0.%2a
+ false
+ false
+ true
+
+
+ bin\Debug\
+ false
+ 285212672
+ false
+
+ DEBUG;TRACE
+
+ true
+ 4096
+ false
+ false
+ false
+ false
+ 4
+ full
+ prompt
+
+
+ bin\Release\
+ false
+ 285212672
+ false
+
+ TRACE
+
+ false
+ 4096
+ true
+ false
+ false
+ false
+ 4
+ none
+ prompt
+
+
+
+ dotMath
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}
+ {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+
+
+ ..\packages\NUnit.2.6.3\lib\nunit.framework.dll
+
+
+ System
+
+
+ System.Data
+
+
+ System.XML
+
+
+
+
+ Code
+
+
+ Code
+
+
+ Code
+
+
+
+
+ False
+ .NET Framework 3.5 SP1 Client Profile
+ false
+
+
+ False
+ .NET Framework 3.5 SP1
+ true
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Tests/VariableOutputTests.cs b/Tests/VariableOutputTests.cs
new file mode 100644
index 0000000..554f974
--- /dev/null
+++ b/Tests/VariableOutputTests.cs
@@ -0,0 +1,368 @@
+using System;
+using NUnit.Framework;
+
+namespace dotMath.Tests
+{
+ [TestFixture]
+ public class VariableOutputTests
+ {
+ private double m_a = -4;
+ private double m_b = 4;
+ private double m_c = -8;
+ private double m_d = 8;
+
+ private void InitVarRun()
+ {
+ m_a = -100;
+ m_b = 100;
+ m_c = -100;
+ m_d = 100;
+ }
+
+ private void StrobeValues()
+ {
+ m_a += 1;
+ m_b -= 1;
+ m_c += .125;
+ m_d -= .125;
+ }
+
+ [Test]
+ public void RangeTest()
+ {
+ InitVarRun();
+
+ for (int i = 0; i < 200; i++)
+ {
+ Abs();
+ Acos();
+ Addition();
+ Asin();
+ Atan();
+ Ceiling();
+ ConstantExpression();
+ Cos();
+ Cosh();
+ Division();
+ Exp();
+ Exponent();
+ Floor();
+ IfElse();
+ IfThen();
+ Log();
+ Log10();
+ Max();
+ Min();
+ MultipleFunctionsPerObject();
+ Multiplication();
+ NestedFunctions();
+ Round();
+ Sign();
+ SignNeg();
+ Sin();
+ Sinh();
+ Subtraction();
+ Tan();
+ Tanh();
+
+ StrobeValues();
+ }
+ }
+
+ private EqCompiler GetCompilerSetup(string sFunction)
+ {
+ EqCompiler oComp = new EqCompiler(sFunction, true);
+ oComp.SetVariable("a", m_a);
+ oComp.SetVariable("b", m_b);
+ oComp.SetVariable("c", m_c);
+ oComp.SetVariable("d", m_d);
+
+ return oComp;
+ }
+
+ [Test]
+ public void ConstantExpression()
+ {
+ EqCompiler oComp = GetCompilerSetup("a");
+
+ Assert.AreEqual(m_a, oComp.Calculate());
+ }
+
+
+ [Test]
+ public void SignNeg()
+ {
+ EqCompiler oComp = GetCompilerSetup("-a");
+
+ Assert.AreEqual(-m_a, oComp.Calculate());
+ }
+
+ [Test]
+ public void Addition()
+ {
+ EqCompiler oComp = GetCompilerSetup("a+b");
+
+ Assert.AreEqual(m_a + m_b, oComp.Calculate());
+ }
+
+ [Test]
+ public void Multiplication()
+ {
+ EqCompiler oComp = GetCompilerSetup("a*b");
+
+ Assert.AreEqual(m_a * m_b, oComp.Calculate());
+ }
+
+ [Test]
+ public void Division()
+ {
+ EqCompiler oComp = GetCompilerSetup("a/b");
+
+ Assert.AreEqual(m_a / m_b, oComp.Calculate());
+ }
+
+ [Test]
+ public void Subtraction()
+ {
+ EqCompiler oComp = GetCompilerSetup("a-b");
+
+ Assert.AreEqual(m_a - m_b, oComp.Calculate());
+ }
+
+ [Test]
+ public void Exponent()
+ {
+ EqCompiler oComp = GetCompilerSetup("a^b");
+
+ Assert.AreEqual(Math.Pow(m_a, m_b), oComp.Calculate());
+ }
+
+ [Test]
+ public void MultipleFunctionsPerObject()
+ {
+ EqCompiler oComp = GetCompilerSetup("abs(b)");
+ Assert.AreEqual(Math.Abs(m_b), oComp.Calculate());
+
+ oComp.SetFunction("acos(a)");
+ Assert.AreEqual(Math.Acos(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void NestedFunctions()
+ {
+ EqCompiler oComp = GetCompilerSetup("sin(cos(tan(a)))");
+
+ Assert.AreEqual(Math.Sin(Math.Cos(Math.Tan(m_a))), oComp.Calculate());
+ }
+
+ [Test]
+ public void Abs()
+ {
+ EqCompiler oComp = GetCompilerSetup("abs(-a)");
+
+ Assert.AreEqual(Math.Abs(-m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Acos()
+ {
+ EqCompiler oComp = GetCompilerSetup("acos(a)");
+
+ Assert.AreEqual(Math.Acos(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Asin()
+ {
+ EqCompiler oComp = GetCompilerSetup("asin(a)");
+
+ Assert.AreEqual(Math.Asin(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Atan()
+ {
+ EqCompiler oComp = GetCompilerSetup("atan(a)");
+
+ Assert.AreEqual(Math.Atan(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Ceiling()
+ {
+ EqCompiler oComp = GetCompilerSetup("ceiling(b)");
+
+ Assert.AreEqual(Math.Ceiling(m_b), oComp.Calculate());
+ }
+
+ [Test]
+ public void Cos()
+ {
+ EqCompiler oComp = GetCompilerSetup("cos(b)");
+
+ Assert.AreEqual(Math.Cos(m_b), oComp.Calculate());
+ }
+
+ [Test]
+ public void Cosh()
+ {
+ EqCompiler oComp = GetCompilerSetup("cosh(a)");
+
+ Assert.AreEqual(Math.Cosh(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Exp()
+ {
+ EqCompiler oComp = GetCompilerSetup("exp(a)");
+
+ Assert.AreEqual(Math.Exp(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Floor()
+ {
+ EqCompiler oComp = GetCompilerSetup("floor(-a)");
+
+ Assert.AreEqual(Math.Floor(-m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Log()
+ {
+ EqCompiler oComp = GetCompilerSetup("log(a)");
+
+ Assert.AreEqual(Math.Log(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Log10()
+ {
+ EqCompiler oComp = GetCompilerSetup("log10(a)");
+
+ Assert.AreEqual(Math.Log10(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Round()
+ {
+ EqCompiler oComp = GetCompilerSetup("round(a)");
+
+ Assert.AreEqual(Math.Round(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sign()
+ {
+ EqCompiler oComp = GetCompilerSetup("sign(-a)");
+
+ Assert.AreEqual(Math.Sign(-m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sin()
+ {
+ EqCompiler oComp = GetCompilerSetup("sin(a)");
+
+ Assert.AreEqual(Math.Sin(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sinh()
+ {
+ EqCompiler oComp = GetCompilerSetup("sinh(a)");
+
+ Assert.AreEqual(Math.Sinh(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Sqrt()
+ {
+ EqCompiler oComp = GetCompilerSetup("sqrt(a)");
+
+ Assert.AreEqual(Math.Sqrt(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Tan()
+ {
+ EqCompiler oComp = GetCompilerSetup("tan(a)");
+
+ Assert.AreEqual(Math.Tan(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Tanh()
+ {
+ EqCompiler oComp = GetCompilerSetup("tanh(a)");
+
+ Assert.AreEqual(Math.Tanh(m_a), oComp.Calculate());
+ }
+
+ [Test]
+ public void Max()
+ {
+ EqCompiler oComp = GetCompilerSetup("max(a,b,c,d)");
+ double dMax = m_a;
+
+ if (dMax < m_b)
+ dMax = m_b;
+ if (dMax < m_c)
+ dMax = m_c;
+ if (dMax < m_d)
+ dMax = m_d;
+
+ Assert.AreEqual(dMax, oComp.Calculate());
+ }
+
+ [Test]
+ public void Min()
+ {
+ EqCompiler oComp = GetCompilerSetup("min(a,b,c,d)");
+
+ double dMin = m_a;
+ if (dMin > m_b)
+ dMin = m_b;
+ if (dMin > m_c)
+ dMin = m_c;
+ if (dMin > m_d)
+ dMin = m_d;
+
+ Assert.AreEqual(dMin, oComp.Calculate());
+ }
+
+ [Test]
+ public void IfThen()
+ {
+ string sTest;
+ if (m_a < m_b)
+ sTest = "if(a
+
+
+
\ No newline at end of file
diff --git a/dotMath.sln b/dotMath.sln
new file mode 100644
index 0000000..12145db
--- /dev/null
+++ b/dotMath.sln
@@ -0,0 +1,26 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2012
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "dotMath", "dotMath\dotMath.csproj", "{B2EBEDE8-441A-4CC2-80FF-5F290D528919}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tests", "Tests\Tests.csproj", "{1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}.Release|Any CPU.Build.0 = Release|Any CPU
+ {1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {1961B8D4-3A8B-4DC0-94A2-1781A092AFFE}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/dotMath/EqCompiler.cs b/dotMath/EqCompiler.cs
new file mode 100644
index 0000000..542a72e
--- /dev/null
+++ b/dotMath/EqCompiler.cs
@@ -0,0 +1,1240 @@
+using System;
+using System.Collections;
+
+namespace dotMath
+{
+ ///
+ /// Copyright (c) 2001-2004, Stephen Hebert
+ /// All rights reserved.
+ ///
+ ///
+ /// Redistribution and use in source and binary forms, with or without modification,
+ /// are permitted provided that the following conditions are met:
+ ///
+ /// Redistributions of source code must retain the above copyright notice,
+ /// this list of conditions and the following disclaimer.
+ ///
+ /// Redistributions in binary form must reproduce the above
+ /// copyright notice, this list of conditions and the following disclaimer
+ /// in the documentation and/or other materials provided with the distribution.
+ ///
+ /// Neither the name of the .Math, nor the names of its contributors
+ /// may be used to endorse or promote products derived from this software without
+ /// specific prior written permission.
+ ///
+ /// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ /// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ /// TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ /// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
+ /// BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
+ /// OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ /// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+ /// OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ /// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ /// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ /// EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ ///
+ ///
+ ///
+ ///
+ /// EqCompiler is the class that takes the parsed tokens and turns them
+ /// into a network of pre-compiled objects that perform the designated
+ /// functions.
+ ///
+ public class EqCompiler
+ {
+ private string m_sEquation;
+ private CValue m_Function;
+ private Parser.Token m_currentToken;
+ private Parser.Token m_nextToken;
+ private IEnumerator m_enumTokens;
+ private SortedList m_slVariables = new SortedList();
+ private SortedList m_slFunctions = new SortedList();
+ private SortedList m_slOperations = new SortedList();
+
+ private COperator[] m_aOps;
+
+ #region Operations and Compiling Functions
+
+ ///
+ /// CSignNeg provides negative number functionality
+ /// within an equation.
+ ///
+ private class CSignNeg : CValue
+ {
+ CValue m_oValue;
+
+ ///
+ /// CSignNeg constructor: Grabs onto the assigned
+ /// CValue object and retains it for processing
+ /// requested operations.
+ ///
+ /// Child operation this object operates upon.
+ public CSignNeg(CValue oValue)
+ {
+ m_oValue = oValue;
+ }
+
+ ///
+ /// GetValue(): Performs the negative operation on the child operation and returns the value.
+ ///
+ /// A double value evaluated and returned with the opposite sign.
+ public override double GetValue()
+ {
+ return m_oValue.GetValue() * -1;
+ }
+ }
+
+ ///
+ /// Paren() : This method evaluates Parenthesis in the equation and
+ /// insures they are handled properly according to the Order of Operations. Because this is last in the chain,
+ /// it also evaluates Variable and Function names.
+ ///
+ /// CValue object that holds an operation.
+ private CValue Paren()
+ {
+ bool bFunc = false;
+ CValue oValue = null;
+
+ if (m_currentToken.ToString() == "(")
+ {
+ PositionNextToken();
+
+ oValue = Relational();
+
+ if (m_currentToken.ToString() == ",")
+ return oValue;
+
+ if (m_currentToken.ToString() != ")")
+ throw new ApplicationException("Unmatched parenthesis in equation.");
+ }
+ else
+ {
+ switch (m_currentToken.TokenType)
+ {
+ case Parser.CharType.CT_NUMBER:
+ oValue = new CNumber(m_currentToken.ToString());
+ break;
+
+ case Parser.CharType.CT_LETTER:
+ if (m_nextToken.ToString() == "(")
+ {
+ int iIdx = m_slFunctions.IndexOfKey(m_currentToken.ToString());
+
+ if (iIdx < 0)
+ throw new ApplicationException("Function not found - " + m_currentToken.ToString());
+
+ CFunction oFunc = (CFunction) m_slFunctions.GetByIndex(iIdx);
+
+ ArrayList alValues = new ArrayList();
+
+ do
+ {
+ PositionNextToken();
+ oValue = Paren();
+
+ alValues.Add(oValue);
+ }
+ while (m_currentToken.ToString() == ",");
+
+ bFunc = true;
+
+ oValue = oFunc.CreateInstance(alValues);
+ }
+ else
+ oValue = GetVariableByName(m_currentToken.ToString());
+
+ break;
+ }
+ }
+
+ if (!bFunc)
+ PositionNextToken();
+
+ return oValue;
+ }
+
+ ///
+ /// Sign(): This method detects the existence of sign operators before
+ /// a number or variable.
+ ///
+ /// CValue object representing an operation.
+ private CValue Sign()
+ {
+ bool bNeg = false;
+ Parser.Token oToken = null;
+
+ if (m_currentToken == "+" || m_currentToken == "-")
+ {
+ oToken = m_currentToken;
+ bNeg = (m_currentToken == "-");
+ PositionNextToken();
+ }
+
+ //CValue oFunc = Function();
+ // sdh: should be function when ready.
+ CValue oFunc = Paren();
+
+ if (bNeg)
+ {
+ CheckParms(oToken, oFunc);
+ oFunc = new CSignNeg(oFunc);
+ }
+
+ return oFunc;
+ }
+
+ ///
+ /// Power(): Detects the operation to raise one number to the power
+ /// of another (a^2).
+ ///
+ /// CValue object representing an operation.
+ private CValue Power()
+ {
+ CValue oValue = Sign();
+
+ while (m_currentToken == "^")
+ {
+ Parser.Token oOp = m_currentToken;
+
+ PositionNextToken();
+
+ CValue oNextVal = Sign();
+
+ CheckParms(oOp, oValue, oNextVal);
+ oValue = OpFactory(oOp, oValue, oNextVal);
+ }
+
+ return oValue;
+ }
+
+ ///
+ /// MultDiv(): Detects the operation to perform multiplication or division.
+ ///
+ /// CValue object representing an operation.
+ private CValue MultDiv()
+ {
+ CValue oValue = Power();
+
+ while (m_currentToken == "*" || m_currentToken == "/")
+ {
+ Parser.Token oOp = m_currentToken;
+
+ PositionNextToken();
+
+ CValue oNextVal = Power();
+
+ CheckParms(oOp, oValue, oNextVal);
+ oValue = OpFactory(oOp, oValue, oNextVal);
+ }
+
+ return oValue;
+ }
+
+ ///
+ /// AddSub(): Detects the operation to perform addition or substraction.
+ ///
+ /// CValue object representing an operation.
+ private CValue AddSub()
+ {
+ CValue oValue = MultDiv();
+
+ while (m_currentToken == "+" || m_currentToken == "-")
+ {
+ Parser.Token oOp = m_currentToken;
+ PositionNextToken();
+
+ CValue oNextVal = MultDiv();
+
+ CheckParms(oOp, oValue, oNextVal);
+ oValue = OpFactory(oOp, oValue, oNextVal);
+ }
+
+ return oValue;
+ }
+
+ ///
+ /// Relational(): Detects the operation to perform a relational operator (>, <, <=, etc.).
+ ///
+ /// CValue object representing an operation.
+ private CValue Relational()
+ {
+ CValue oValue = AddSub();
+
+ while (m_currentToken == "&&" ||
+ m_currentToken == "||" ||
+ m_currentToken == "==" ||
+ m_currentToken == "<" ||
+ m_currentToken == ">" ||
+ m_currentToken == "<=" ||
+ m_currentToken == ">=" ||
+ m_currentToken == "!=" ||
+ m_currentToken == "<>")
+ {
+ Parser.Token oOp = m_currentToken;
+ PositionNextToken();
+ CValue oNextVal = Relational();
+
+ CheckParms(oOp, oValue, oNextVal);
+ oValue = OpFactory(oOp, oValue, oNextVal);
+ }
+
+ return oValue;
+ }
+
+ ///
+ /// OpFactor(...): Reads the passed operator, identifies the associated implementation object
+ /// and requests an operation object to be used in evaluating the equation.
+ ///
+ /// Parser.Token object representing the operator in question.
+ /// The first value object to be operated on.
+ /// The second value object to be operated on.
+ /// CValue object representing an operation.
+ private CValue OpFactory(Parser.Token oSourceOp, CValue oValue1, CValue oValue2)
+ {
+ foreach (COperator oOp in m_aOps)
+ {
+ if (oOp.IsMatch(oSourceOp))
+ return oOp.Factory(oValue1, oValue2);
+ }
+
+ throw new ApplicationException("Invalid operator in equation.");
+ }
+
+ #endregion
+
+ #region Core Base Classes
+
+ ///
+ /// CBalue class: This base is the basic building block of
+ /// all operations, variables, functions, etc.. Any object
+ /// may call to a CValue object asking for it to resolve itself
+ /// and return it's processed value.
+ ///
+ public abstract class CValue
+ {
+ public abstract double GetValue();
+ }
+
+ ///
+ /// CVariable class : Derived from CValue, CVariable implements
+ /// a named expression variable, holding the name and associated value.
+ /// This object is accessed when an expression is evaluated or when
+ /// a user sets a variable value.
+ ///
+ public class CVariable : CValue
+ {
+ private string m_sVarName;
+ private double m_dValue;
+
+ ///
+ /// CVariable(string) constructor: Creates the object and holds onto the
+ /// compile-time assigned variable name.
+ ///
+ /// Name of the variable within the expression.
+ public CVariable(string sVarName)
+ {
+ m_sVarName = sVarName;
+ }
+
+ ///
+ /// CVariable(string,double) constructor: Creates the objects and holds onto the
+ /// compile-time assigned variable name and value.
+ ///
+ /// string containing the variable name
+ /// double containing the assigned variable value
+ public CVariable(string sVarName, double dValue)
+ {
+ m_sVarName = sVarName;
+ }
+
+ ///
+ /// SetValue(): Allows the setting of the variables value at runtime.
+ ///
+ ///
+ public void SetValue(double dValue)
+ {
+ m_dValue = dValue;
+ }
+
+ ///
+ /// GetValue(): Returns the value of the variable to the calling client.
+ ///
+ /// double
+ public override double GetValue()
+ {
+ return m_dValue;
+ }
+ }
+
+ ///
+ /// CNumber Class: A CValue-derived class that implements a static
+ /// numeric value in an expression.
+ ///
+ public class CNumber : CValue
+ {
+ private double m_dValue;
+
+ ///
+ /// CNumber(string) constructor: take a string representation of a static number
+ /// and stores it for future retrieval.
+ ///
+ /// string/text representation of a number
+ public CNumber(string sValue)
+ {
+ m_dValue = Convert.ToDouble(sValue);
+ }
+
+ ///
+ /// CNumber(double) constructor: takes a double represenation of a static number
+ /// and stores it for future retrieval.
+ ///
+ ///
+ public CNumber(double dValue)
+ {
+ m_dValue = dValue;
+ }
+
+ ///
+ /// GetValue(): returns the static value when called upon.
+ ///
+ /// double
+ public override double GetValue()
+ {
+ return m_dValue;
+ }
+ }
+
+ ///
+ /// COperator class: A CValue derived class responsible for identifying
+ /// and implementing operations during the parsing and evaluation processes.
+ ///
+ private abstract class COperator : CValue
+ {
+ ///
+ /// IsMatch(): accepts an operation token and identifies if the implemented
+ /// operator class is responsible for it. This allows for multiple operators
+ /// to represent a given operation (i.e. != and <> both represent the "not-equal" case.
+ ///
+ /// Parser.Token containing the operator in question
+ /// bool returning true if the object is reponsible for implementing the operator at hand.
+ public abstract bool IsMatch(Parser.Token tkn);
+
+ ///
+ /// Factory(CValue, CValue): responsible for providing an evaluation-time object that
+ /// holds onto the CValue objects it is responsible for operating on.
+ ///
+ /// First CValue object to operate on
+ /// Second CValue object to operate on
+ /// "Evaluation time" COperator object
+ public abstract COperator Factory(CValue arg1, CValue arg2);
+
+ ///
+ /// CheckParms( string, CValue, CValue): Helper function that verifies the two arguments
+ /// are non-null objects. If not, an exception is thrown.
+ ///
+ /// string representing the operation.
+ /// CValue object representing the first operation
+ /// CValue object representing the second oepration
+ protected void CheckParms(string sOp, CValue arg1, CValue arg2)
+ {
+ if (arg1 == null || arg2 == null)
+ throw new ApplicationException("Missing expression on " + sOp + " operator.");
+ }
+ }
+
+ ///
+ /// CFunction class: A CValue derived class that provdes the base for all functions
+ /// implemented in the compiler. This class also allows for external clients to
+ /// create and register functions with the compiler - thereby extending the compilers
+ /// syntax and functionality.
+ ///
+ public abstract class CFunction : CValue
+ {
+ ///
+ /// GetFunction(): returns the function name as a string
+ ///
+ /// string
+ public abstract string GetFunction();
+
+ ///
+ /// SetValue(): Accepts an array of CValue objects that represent the parameters in
+ /// the function.
+ ///
+ /// ArrayList of CValue parameter objects.
+ public abstract void SetValue(ArrayList alValues);
+
+ ///
+ /// CreateInstance( ArrayList ): Requests that an evaluation-time object be created
+ /// that performs the operation on a set of CValue objects.
+ ///
+ /// ArrayList of CValue parameter objects.
+ /// Returns a CFunction object that references parameters for evaluation purposes.
+ public abstract CFunction CreateInstance(ArrayList alValues);
+
+ ///
+ /// CheckParms(ArrayList, int): Helper function that accepts an array list and insures an appropriate
+ /// number of CValue objects have been passed. If not, an ApplicationException is thrown.
+ ///
+ /// ArrayList of CValue-based objects representing parameters to the function
+ /// integer: required parameter count
+ protected void CheckParms(ArrayList alValues, int iRequiredValueCount)
+ {
+ if (alValues.Count != iRequiredValueCount)
+ {
+ string sMsg = string.Format("Invalid parameter count. Function '" + GetFunction() + "' requires {0} parameter(s).", iRequiredValueCount);
+ throw new ApplicationException(sMsg);
+ }
+ }
+
+ ///
+ /// CheckParms(ArrayList, int, int): Helper function that accepts an array list and insures an appropriate
+ /// number (min and/or max) of CValue objects have been passed. If not an ApplicationException is thrown.
+ ///
+ /// ArrayList of CValue object that have been passed by the compiler.
+ /// int value indicating a minimum number of parameters. -1 if no minimum exists
+ /// int value indicating a maximum number of parameters. -1 if no maximum exists
+ protected void CheckParms(ArrayList alValues, int iMinReq, int iMaxReq)
+ {
+ if (iMinReq > -1)
+ {
+ if (iMinReq > alValues.Count)
+ {
+ string sMsg = string.Format("Invalid parameter count. Function '" + GetFunction() + "' requires a minimum of {0} parameter(s).", iMinReq);
+ throw new ApplicationException(sMsg);
+ }
+ }
+
+ if (iMaxReq > -1)
+ {
+ if (iMaxReq < alValues.Count)
+ {
+ string sMsg = string.Format("Invalid parameter count. Function '" + GetFunction() + "' is limited to a maximum of {0} parameter(s).", iMaxReq);
+ throw new ApplicationException(sMsg);
+ }
+ }
+ }
+ }
+
+ #endregion
+
+ #region Operators
+
+ ///
+ /// CAdd class: Implements the Add(+) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CAdd : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CAdd()
+ {
+ }
+
+ public CAdd(CValue arg1, CValue arg2)
+ {
+ CheckParms("+", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ return m_arg1.GetValue() + m_arg2.GetValue();
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "+");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CAdd(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CSubtract class: Implements the Subtract(-) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CSubtract : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CSubtract()
+ {
+ }
+
+ public CSubtract(CValue arg1, CValue arg2)
+ {
+ CheckParms("-", arg1, arg2);
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ return m_arg1.GetValue() - m_arg2.GetValue();
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return tkn.ToString() == "-";
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CSubtract(arg1, arg2);
+ }
+ }
+
+
+ ///
+ /// CLessThan class: Implements the LessThan operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CLessThan : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CLessThan()
+ {
+ }
+
+ public CLessThan(CValue arg1, CValue arg2)
+ {
+ CheckParms("<", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() < m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "<");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CLessThan(arg1, arg2);
+ }
+ }
+
+ ///
+ /// COr class: Implements the boolean Or(||) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class COr : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public COr()
+ {
+ }
+
+ public COr(CValue arg1, CValue arg2)
+ {
+ CheckParms("||", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() != 0 || m_arg2.GetValue() != 0)
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "||");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new COr(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CAnd class: Implements the boolean And(&&) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CAnd : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CAnd()
+ {
+ }
+
+ public CAnd(CValue arg1, CValue arg2)
+ {
+ CheckParms("&&", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() != 0 && m_arg2.GetValue() != 0)
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "&&");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CAnd(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CEqual class: Implements the binary Equal(==) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CEqual : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CEqual()
+ {
+ }
+
+ public CEqual(CValue arg1, CValue arg2)
+ {
+ CheckParms("= or ==", arg1, arg2);
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() == m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "=" || tkn.ToString() == "==");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CEqual(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CNotEqual class: Implements the NotEqual(<>) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CNotEqual : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CNotEqual()
+ {
+ }
+
+ public CNotEqual(CValue arg1, CValue arg2)
+ {
+ CheckParms("<> or !=", arg1, arg2);
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() != m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "!=" || tkn.ToString() == "<>");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CNotEqual(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CGreaterThan class: Implements the Greater Than(>) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CGreaterThan : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CGreaterThan()
+ {
+ }
+
+ public CGreaterThan(CValue arg1, CValue arg2)
+ {
+ CheckParms(">", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() > m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == ">");
+ }
+
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CGreaterThan(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CGreaterThanEq class: Implements the Greater Than or Equal To(>=) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CGreaterThanEq : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CGreaterThanEq()
+ {
+ }
+
+ public CGreaterThanEq(CValue arg1, CValue arg2)
+ {
+ CheckParms(">=", arg1, arg2);
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() >= m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == ">=");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CGreaterThanEq(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CLessThanEq class: Implements the Less Than or Equal To(<=) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CLessThanEq : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CLessThanEq()
+ {
+ }
+
+ public CLessThanEq(CValue arg1, CValue arg2)
+ {
+ CheckParms("<=", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ if (m_arg1.GetValue() <= m_arg2.GetValue())
+ return 1;
+ else
+ return 0;
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "<=");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CLessThanEq(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CMultiply class: Implements the Multiplication(*) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CMultiply : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CMultiply()
+ {
+ }
+
+ public CMultiply(CValue arg1, CValue arg2)
+ {
+ CheckParms("*", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ return m_arg1.GetValue() * m_arg2.GetValue();
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "*");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CMultiply(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CDivide class: Implements the Division(/) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CDivide : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CDivide()
+ {
+ }
+
+ public CDivide(CValue arg1, CValue arg2)
+ {
+ CheckParms("/", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ return m_arg1.GetValue() / m_arg2.GetValue();
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "/");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CDivide(arg1, arg2);
+ }
+ }
+
+ ///
+ /// CPower class: Implements the Power(^) operation. Refer to COperator base class
+ /// for a description of the methods.
+ ///
+ private class CPower : COperator
+ {
+ private CValue m_arg1 = null;
+ private CValue m_arg2 = null;
+
+ public CPower()
+ {
+ }
+
+ public CPower(CValue arg1, CValue arg2)
+ {
+ CheckParms("^", arg1, arg2);
+
+ m_arg1 = arg1;
+ m_arg2 = arg2;
+ }
+
+ public override double GetValue()
+ {
+ return Math.Pow(m_arg1.GetValue(), m_arg2.GetValue());
+ }
+
+ public override bool IsMatch(Parser.Token tkn)
+ {
+ return (tkn.ToString() == "^");
+ }
+
+ public override COperator Factory(CValue arg1, CValue arg2)
+ {
+ return new CPower(arg1, arg2);
+ }
+ }
+
+ #endregion
+
+ #region Helper Functions
+
+ ///
+ /// CheckParms( Parser.Token, CValue, CValue) - This method makes certain the arguments are non-null
+ ///
+ /// Currently processed Parser.Token object
+ /// CValue argument 1
+ /// CValue argument 2
+ private void CheckParms(Parser.Token oToken, CValue arg1, CValue arg2)
+ {
+ if (arg1 == null || arg2 == null)
+ throw new ApplicationException("Argument not supplied near " + oToken.ToString() + " operation.");
+ }
+
+ ///
+ /// CheckParms( Parser.Token, CValue) - This method makes certain the single argument is non-null.
+ /// Raises an exception if it is.
+ ///
+ /// Parser.Token object
+ /// CValue argument
+ private void CheckParms(Parser.Token oToken, CValue arg1)
+ {
+ if (arg1 == null)
+ throw new ApplicationException("Argument not supplied near " + oToken.ToString() + " operation.");
+ }
+
+ ///
+ /// InitFunctions(): Creates all operation functions recognized by the compiler.
+ ///
+ private void InitFunctions()
+ {
+ m_aOps = new COperator[11];
+
+ m_aOps[0] = new CAdd();
+ m_aOps[1] = new CSubtract();
+ m_aOps[2] = new CMultiply();
+ m_aOps[3] = new CDivide();
+ m_aOps[4] = new CGreaterThan();
+ m_aOps[5] = new CGreaterThanEq();
+ m_aOps[6] = new CLessThan();
+ m_aOps[7] = new CLessThanEq();
+ m_aOps[8] = new CEqual();
+ m_aOps[9] = new CNotEqual();
+ m_aOps[10] = new CPower();
+ }
+
+ ///
+ /// PositionNextToken(): Manipulates the current Token position forward in the chain of tokens
+ /// discovered by the parser.
+ ///
+ private void PositionNextToken()
+ {
+ if (m_currentToken == null)
+ {
+ if (!m_enumTokens.MoveNext())
+ throw new ApplicationException("Invalid equation.");
+
+ m_nextToken = (Parser.Token) m_enumTokens.Current;
+ }
+
+ m_currentToken = m_nextToken;
+
+ if (!m_enumTokens.MoveNext())
+ m_nextToken = new Parser.Token();
+ else
+ m_nextToken = (Parser.Token) m_enumTokens.Current;
+ }
+
+
+ ///
+ /// GetVariableByName(string) : This method returns the variable associated with the
+ /// provided name string.
+ ///
+ /// string variable name
+ /// CVariable object mapped to the passed variable name
+ private CVariable GetVariableByName(string sVarName)
+ {
+ if (m_slVariables == null)
+ m_slVariables = new SortedList();
+
+ int iIdx = m_slVariables.IndexOfKey(sVarName);
+
+ if (iIdx > -1)
+ return (CVariable) m_slVariables.GetByIndex(iIdx);
+
+ CVariable oVar = new CVariable(sVarName);
+ m_slVariables.Add(sVarName, oVar);
+
+ return oVar;
+ }
+
+ #endregion
+
+ ///
+ /// VariableCount property: This property reports the current
+ /// variable count. It is valid after a 'Compile()' function is executed.
+ ///
+ public int VariableCount { get { return m_slVariables.Count; } }
+
+ ///
+ /// SetVariable( string, double): Sets the object mapped to the string variable name
+ /// to the double value passed.
+ ///
+ /// Variable Name
+ /// New Value for variable
+ public void SetVariable(string sVarName, double dValue)
+ {
+ CVariable oVar = GetVariableByName(sVarName);
+ oVar.SetValue(dValue);
+ }
+
+ ///
+ /// GetVariableList(): returns a string array containing all the variables that
+ /// have been found by the compiler.
+ ///
+ /// string array of current variable names
+ public string[] GetVariableList()
+ {
+ if (m_slVariables.Count == 0)
+ return null;
+
+ string[] asVars = new string[m_slVariables.Count];
+
+ IEnumerator enu = m_slVariables.GetKeyList().GetEnumerator();
+
+ string sValue = "";
+ int iPos = 0;
+
+ while (enu.MoveNext())
+ {
+ sValue = (string) enu.Current;
+
+ asVars[iPos] = sValue;
+ iPos++;
+ }
+
+ return asVars;
+ }
+
+ ///
+ /// EqCompiler() constructor: creates the compiler object with an empty function that returns '0' if evaluated.
+ ///
+ public EqCompiler(bool bIncludeStandardFunctions)
+ {
+ SetFunction("0");
+
+ if (bIncludeStandardFunctions)
+ CFunctionLibrary.AddFunctions(this);
+ }
+
+ ///
+ /// EqCompiler(string) constructor: creates the compiler object and sets the current function to the string passed
+ ///
+ ///
+ public EqCompiler(string sEquation, bool bIncludeStandardFunctions)
+ {
+ SetFunction(sEquation);
+
+ if (bIncludeStandardFunctions)
+ CFunctionLibrary.AddFunctions(this);
+ }
+
+ ///
+ /// SetFunction(string): Sets the current function to a passed string.
+ ///
+ /// string representing the function being used
+ public void SetFunction(string sEquation)
+ {
+ m_currentToken = null;
+ m_nextToken = null;
+
+ m_sEquation = sEquation;
+ m_Function = null;
+ InitFunctions();
+ }
+
+ ///
+ /// Compile(): This function kicks off the process to tokenize the function
+ /// and compile the resulting token set into a runnable form.
+ ///
+ public void Compile()
+ {
+ Parser oParser = new Parser(m_sEquation);
+ m_enumTokens = oParser.GetTokenEnumerator();
+
+ PositionNextToken();
+
+ m_Function = Relational();
+ }
+
+ ///
+ /// Calculate(): Calls into the runnable function set to evaluate the function and returns the result.
+ ///
+ /// double value evaluation of the function in its current state
+ public double Calculate()
+ {
+ if (m_Function == null)
+ Compile();
+
+ return m_Function.GetValue();
+ }
+
+ ///
+ /// AddFunction(CFunction): This member accepts a function object and
+ /// adds it to the compilers set of functions.
+ ///
+ /// CFunction object that implements a functionality extension for the compiler.
+ public void AddFunction(CFunction oFunc)
+ {
+ m_slFunctions.Add(oFunc.GetFunction(), oFunc);
+ }
+ }
+}
diff --git a/dotMath/FunctionLib.cs b/dotMath/FunctionLib.cs
new file mode 100644
index 0000000..06a528a
--- /dev/null
+++ b/dotMath/FunctionLib.cs
@@ -0,0 +1,883 @@
+using System;
+using System.Collections;
+
+namespace dotMath
+{
+ ///
+ /// Copyright (c) 2001-2004, Stephen Hebert
+ /// All rights reserved.
+ ///
+ ///
+ /// Redistribution and use in source and binary forms, with or without modification,
+ /// are permitted provided that the following conditions are met:
+ ///
+ /// Redistributions of source code must retain the above copyright notice,
+ /// this list of conditions and the following disclaimer.
+ ///
+ /// Redistributions in binary form must reproduce the above
+ /// copyright notice, this list of conditions and the following disclaimer
+ /// in the documentation and/or other materials provided with the distribution.
+ ///
+ /// Neither the name of the .Math, nor the names of its contributors
+ /// may be used to endorse or promote products derived from this software without
+ /// specific prior written permission.
+ ///
+ /// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ /// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ /// TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ /// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
+ /// BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
+ /// OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ /// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+ /// OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ /// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ /// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ /// EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ ///
+ ///
+ ///
+ ///
+ /// CFunctionLibrary provides additional math functions to the
+ /// equation compiler. All functions may be added to the file using
+ /// a static member variable.
+ ///
+ public class CFunctionLibrary
+ {
+ ///
+ /// AddFunctions(EqCompiler): registers all the functions in the library with
+ /// the provided compiler instance.
+ ///
+ ///
+ /// An incoming instance of the equation compiler.
+ ///
+ ///
+ ///
+ /// EqCompiler comp = new EqCompiler("sqrt(a+b)");
+ /// CFunctionLibrary.AddFunctions( comp );
+ /// comp.Compile();
+ ///
+ ///
+ public static void AddFunctions(EqCompiler eq)
+ {
+ eq.AddFunction(new CAbs());
+ eq.AddFunction(new CAcos());
+ eq.AddFunction(new CAsin());
+ eq.AddFunction(new CAtan());
+ eq.AddFunction(new CCeiling());
+ eq.AddFunction(new CCos());
+ eq.AddFunction(new CCosh());
+ eq.AddFunction(new CExp());
+ eq.AddFunction(new CFloor());
+ eq.AddFunction(new CLog());
+ eq.AddFunction(new CLog10());
+ eq.AddFunction(new CMax());
+ eq.AddFunction(new CMin());
+ eq.AddFunction(new CRound());
+ eq.AddFunction(new CSign());
+ eq.AddFunction(new CSin());
+ eq.AddFunction(new CSinh());
+ eq.AddFunction(new CSqrt());
+ eq.AddFunction(new CTan());
+ eq.AddFunction(new CTanh());
+ eq.AddFunction(new CIf());
+ }
+ }
+
+ ///
+ /// CAbs class implements the absolute value (abs(x)) function.
+ ///
+ public class CAbs : EqCompiler.CFunction
+ {
+ ///
+ /// An array of values associated with the function.
+ ///
+ ArrayList m_alValues;
+
+ ///
+ /// CAbs.CreateInstance returns an instance of the CAbs object
+ /// with the passed CValue object(s).
+ ///
+ /// An arraylist of values passed by the compiler.
+ ///
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CAbs oAbs = new CAbs();
+ oAbs.SetValue(alValues);
+
+ return oAbs;
+ }
+
+ ///
+ /// CAbs.SetValue() retains the values in the arraylist for the current instance
+ ///
+ /// Arraylist of CValue objects
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ ///
+ /// GetValue() is called by the compiler when the user requests the
+ /// function to be evaluated.
+ ///
+ ///
+ /// a double value with absolute value applied to the
+ /// child parameter
+ ///
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Abs(oValue.GetValue());
+ }
+
+ ///
+ /// GetFunction() returns the function name as it appears syntactically
+ /// to the compiler.
+ ///
+ ///
+ public override string GetFunction()
+ {
+ return "abs";
+ }
+ }
+
+ ///
+ /// CAcos implements calculating the angle whose cosine is the specified number.
+ ///
+ public class CAcos : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ ///
+ /// Creates an instance of CAcos used in the expression compilation.
+ ///
+ /// array list of CValue objects representing
+ /// the indicated child-values
+ /// CFunction-derived object - CAcos
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CAcos oAcos = new CAcos();
+ oAcos.SetValue(alValues);
+
+ return oAcos;
+ }
+
+ ///
+ /// Retains/validates child values used in the calculation.
+ ///
+ /// Array list of CValue objects representing
+ /// indicated child-values.
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ ///
+ /// GetValue returns a double value as a result of running the
+ /// function against child-CValue objects.
+ ///
+ ///
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Acos(oValue.GetValue());
+ }
+
+ ///
+ /// GetFunction() returns the function name according to the syntax
+ /// of the function within the compiler.
+ ///
+ /// string containing the function name
+ public override string GetFunction()
+ {
+ return "acos";
+ }
+ }
+
+ ///
+ /// CAsin implements calculating the angle whose sine is the specified number.
+ ///
+ public class CAsin : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ ///
+ /// CreateInstance() is responsible for createing a new instance
+ /// of this object that can be used in calculations.
+ ///
+ /// Arraylist of CValue objects
+ /// EqCompiler.CFunction
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CAsin oAsin = new CAsin();
+ oAsin.SetValue(alValues);
+
+ return oAsin;
+ }
+
+ ///
+ /// SetValue allows for checking of parameters and storage during compilation.
+ ///
+ /// Set of CValue objects used in calculation.
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ ///
+ /// GetValue() returns the value of the object and it's child members.
+ ///
+ /// double representing the value in the object.
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Asin(oValue.GetValue());
+ }
+
+ ///
+ /// GetFunction() : returns the name of the function.
+ ///
+ ///
+ public override string GetFunction()
+ {
+ return "asin";
+ }
+ }
+
+ ///
+ /// CAtan implements calculating the angle whose tangent is the specified number.
+ ///
+ public class CAtan : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CAtan oAtan = new CAtan();
+ oAtan.SetValue(alValues);
+
+ return oAtan;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Atan(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "atan";
+ }
+ }
+
+ ///
+ /// CFloor class: Returns the largest whole number less than or equal to the specified number.
+ ///
+ public class CFloor : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CFloor oFloor = new CFloor();
+ oFloor.SetValue(alValues);
+
+ return oFloor;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Floor(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "floor";
+ }
+ }
+
+ ///
+ /// CCeiling class: Returns the largest whole number greater than or equal to the specified number.
+ ///
+ public class CCeiling : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CCeiling oCeiling = new CCeiling();
+ oCeiling.SetValue(alValues);
+
+ return oCeiling;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Ceiling(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "ceiling";
+ }
+ }
+
+ ///
+ /// CExp class: Returns e raised to the specified power.
+ ///
+ public class CExp : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CExp oExp = new CExp();
+ oExp.SetValue(alValues);
+
+ return oExp;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Exp(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "exp";
+ }
+ }
+
+ ///
+ /// CSin class: returns the sine of the specified angle.
+ ///
+ public class CSin : EqCompiler.CFunction
+ {
+ EqCompiler.CValue m_oValue;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CSin oSin = new CSin();
+ oSin.SetValue(alValues);
+
+ return oSin;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_oValue = (EqCompiler.CValue) alValues[0];
+ }
+
+ public override double GetValue()
+ {
+ return Math.Sin(m_oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "sin";
+ }
+ }
+
+ ///
+ /// CSinh class: Returns the hyperbolic sine of the specified angle.
+ ///
+ public class CSinh : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CSinh oSinh = new CSinh();
+ oSinh.SetValue(alValues);
+
+ return oSinh;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue1 = (EqCompiler.CValue) m_alValues[0];
+ return Math.Sinh(oValue1.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "sinh";
+ }
+ }
+
+ ///
+ /// CSqrt class: implements the square root function.
+ ///
+ public class CSqrt : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CSqrt oSqrt = new CSqrt();
+ oSqrt.SetValue(alValues);
+
+ return oSqrt;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue1 = (EqCompiler.CValue) m_alValues[0];
+ return Math.Sqrt(oValue1.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "sqrt";
+ }
+ }
+
+ ///
+ /// CCos class: returns the cosine of the specified angle
+ ///
+ public class CCos : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CCos oCos = new CCos();
+ oCos.SetValue(alValues);
+
+ return oCos;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Cos(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "cos";
+ }
+ }
+
+ ///
+ /// CCosh class: returns the hyperbolic cosine of the specified angle
+ ///
+ public class CCosh : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CCosh oCos = new CCosh();
+ oCos.SetValue(alValues);
+
+ return oCos;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Cosh(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "cosh";
+ }
+ }
+
+ ///
+ /// CIf class: implements if(condition, then,else) functionality.
+ ///
+ public class CIf : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CIf oIf = new CIf();
+ oIf.SetValue(alValues);
+
+ return oIf;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 3);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oTest = (EqCompiler.CValue) m_alValues[0];
+ EqCompiler.CValue oThen = (EqCompiler.CValue) m_alValues[1];
+ EqCompiler.CValue oElse = (EqCompiler.CValue) m_alValues[2];
+
+ if (oTest.GetValue() != 0.0)
+ return oThen.GetValue();
+ else
+ return oElse.GetValue();
+ }
+
+ public override string GetFunction()
+ {
+ return "if";
+ }
+ }
+
+ ///
+ /// CMax class: returns the maximum value among provided parameters
+ ///
+ public class CMax : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CMax oMax = new CMax();
+ oMax.SetValue(alValues);
+
+ return oMax;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 2, -1); // check for a minimum of two values (no maximum limit)
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ double dValue = oValue.GetValue();
+
+ for (int i = 1; i < m_alValues.Count; i++)
+ {
+ oValue = (EqCompiler.CValue) m_alValues[i];
+
+ dValue = Math.Max(dValue, oValue.GetValue());
+ }
+
+ return dValue;
+ }
+
+ public override string GetFunction()
+ {
+ return "max";
+ }
+ }
+
+ ///
+ /// CRound class: implements a rouding of a number to the nearest whole number.
+ ///
+ public class CRound : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CRound oRound = new CRound();
+ oRound.SetValue(alValues);
+
+ return oRound;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Round(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "round";
+ }
+ }
+
+ ///
+ /// CSign class: returns a value that indicates the sign of the provide value.
+ /// Returns the following possibilties:
+ /// value < 0 = -1
+ /// value = 0 = 0
+ /// value > 0 = 1
+ ///
+ public class CSign : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CSign oSign = new CSign();
+ oSign.SetValue(alValues);
+
+ return oSign;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Sign(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "sign";
+ }
+ }
+
+ ///
+ /// CMin class: returns the minimum value among supplied values.
+ ///
+ public class CMin : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CMin oMin = new CMin();
+ oMin.SetValue(alValues);
+
+ return oMin;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 2, -1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ double dValue = oValue.GetValue();
+
+ for (int i = 1; i < m_alValues.Count; i++)
+ {
+ oValue = (EqCompiler.CValue) m_alValues[i];
+
+ dValue = Math.Min(dValue, oValue.GetValue());
+ }
+
+ return dValue;
+ }
+
+ public override string GetFunction()
+ {
+ return "min";
+ }
+ }
+
+ ///
+ /// CTan class: return the tagent of the supplied angle
+ ///
+ public class CTan : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CTan oTan = new CTan();
+ oTan.SetValue(alValues);
+
+ return oTan;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Tan(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "tan";
+ }
+ }
+
+ ///
+ /// CLog class: returns the logarithm of a specified number.
+ ///
+ public class CLog : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CLog oLog = new CLog();
+ oLog.SetValue(alValues);
+
+ return oLog;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Log(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "log";
+ }
+ }
+
+ ///
+ /// CLog10 class: Returns the base 10 logarithm of a specified number.
+ ///
+ public class CLog10 : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CLog10 oLog10 = new CLog10();
+ oLog10.SetValue(alValues);
+
+ return oLog10;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Log10(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "log10";
+ }
+ }
+
+ ///
+ /// CTanh class: Returns the hyperbolic tangent of the supplied angle.
+ ///
+ public class CTanh : EqCompiler.CFunction
+ {
+ ArrayList m_alValues;
+
+ public override EqCompiler.CFunction CreateInstance(ArrayList alValues)
+ {
+ CTanh oTanh = new CTanh();
+ oTanh.SetValue(alValues);
+
+ return oTanh;
+ }
+
+ public override void SetValue(ArrayList alValues)
+ {
+ CheckParms(alValues, 1);
+
+ m_alValues = alValues;
+ }
+
+ public override double GetValue()
+ {
+ EqCompiler.CValue oValue = (EqCompiler.CValue) m_alValues[0];
+ return Math.Tanh(oValue.GetValue());
+ }
+
+ public override string GetFunction()
+ {
+ return "tanh";
+ }
+ }
+}
diff --git a/dotMath/Parser.cs b/dotMath/Parser.cs
new file mode 100644
index 0000000..3394f61
--- /dev/null
+++ b/dotMath/Parser.cs
@@ -0,0 +1,356 @@
+using System;
+using System.Collections;
+
+namespace dotMath
+{
+ ///
+ /// Copyright (c) 2001-2004, Stephen Hebert
+ /// All rights reserved.
+ ///
+ ///
+ /// Redistribution and use in source and binary forms, with or without modification,
+ /// are permitted provided that the following conditions are met:
+ ///
+ /// Redistributions of source code must retain the above copyright notice,
+ /// this list of conditions and the following disclaimer.
+ ///
+ /// Redistributions in binary form must reproduce the above
+ /// copyright notice, this list of conditions and the following disclaimer
+ /// in the documentation and/or other materials provided with the distribution.
+ ///
+ /// Neither the name of the .Math, nor the names of its contributors
+ /// may be used to endorse or promote products derived from this software without
+ /// specific prior written permission.
+ ///
+ /// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ /// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ /// TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ /// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
+ /// BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
+ /// OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ /// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+ /// OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ /// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ /// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ /// EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ ///
+ ///
+ ///
+ ///
+ /// Parser class: The Parser class is responsible for traversing a given
+ /// function and creating an enumerable set of tokens.
+ ///
+ public class Parser
+ {
+ ///
+ /// CharType enum: This represents the various types of character types known by the parser.
+ ///
+ public enum CharType
+ {
+ CT_DELIM,
+ CT_WHITESPACE,
+ CT_NUMBER,
+ CT_LETTER,
+ CT_BRACKETS,
+ CT_UNDEF
+ }
+
+ ///
+ /// Token class: The Token class represents a collection of 1 or more characters
+ /// that form a given set of singly definable characters.
+ ///
+ public class Token
+ {
+ private string m_sToken;
+ private CharType m_chType;
+
+ ///
+ /// Equals(Object): Tests for equality with another token. Also
+ /// handles the null case.
+ ///
+ /// string value representing the token being evaluated against.
+ /// bool where true means both objects are equal.
+ public override bool Equals(Object sValue)
+ {
+ if (sValue == null)
+ return m_sToken == null;
+
+ if ((string) sValue == m_sToken)
+ return true;
+ else
+ return false;
+ }
+
+ ///
+ /// operator == (Token, string): This overloaded operator checks for equality between a token and a string.
+ ///
+ /// Token - actual token object
+ /// string - token value to test against token object value
+ ///
+ public static bool operator ==(Token sToken, string sValue)
+ {
+ // the following tests are order dependent. If both are null, eq is true.
+ // if only one is null the eq is false.
+
+ if ((object) sToken == null && sValue == null)
+ return true;
+
+ if ((object) sToken == null || sValue == null)
+ return false;
+
+ if (sToken.m_sToken == sValue)
+ return true;
+ else
+ return false;
+ }
+
+ ///
+ /// operator != (Token, string): Overloaded operator that checks for inequality
+ /// between the token value and the passed string.
+ ///
+ /// Token object being test
+ /// string that is being compared with the Token object's string value
+ /// bool indicating true for inequality
+ public static bool operator !=(Token sToken, string sValue)
+ {
+ if (sToken == null || sValue == null)
+ return !(sToken == null && sValue == null);
+
+ if (sToken.m_sToken != sValue)
+ return true;
+ else
+ return false;
+ }
+
+ ///
+ /// Token(string, CharType) constructor: A constructor that creates a new token object with the
+ /// passed token string and character type information.
+ ///
+ /// string representing the token value
+ /// Character enumeration describing the type of data in the token.
+ public Token(string sToken, CharType chType)
+ {
+ m_sToken = sToken;
+ m_chType = chType;
+ }
+
+ ///
+ /// Token() constructor: creates an empty token
+ ///
+ public Token()
+ {
+ m_sToken = "";
+ m_chType = CharType.CT_UNDEF;
+ }
+
+ ///
+ /// Token(char, CharType) constructor: create a single character token with type info
+ ///
+ /// Single character token value
+ /// Token Type information
+ public Token(char chToken, CharType chType)
+ {
+ m_sToken = "";
+
+ m_sToken += chToken;
+ m_chType = chType;
+ }
+
+ ///
+ /// TokenType property: Returns the Character type associate with the token.
+ ///
+ public CharType TokenType
+ {
+ get
+ {
+ return m_chType;
+ }
+ }
+
+ ///
+ /// ToString() - returns the string name of the token.
+ ///
+ ///
+ public override string ToString()
+ {
+ return m_sToken;
+ }
+ }
+
+ private string m_sFunction;
+ private string m_sWhitespace;
+ private string m_sDelimiters;
+ private string m_sNumbers;
+ private string m_sLetters;
+ private string m_sBrackets;
+ private ArrayList m_alTokens;
+
+ ///
+ /// Parser(string): This function takes an expression and launches the parsing process.
+ ///
+ /// The expression string to be parsed.
+ public Parser(string sFunction)
+ {
+ m_sFunction = sFunction;
+
+ m_sWhitespace = " \t";
+ m_sDelimiters = "+-*/^()<>=&|!,";
+ m_sNumbers = ".0123456789";
+ m_sLetters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz%_";
+ m_sBrackets = "[]";
+
+ Parse();
+ }
+
+ ///
+ /// GetTokenEnumerator(): Gets an enumerator associated with the token collection.
+ ///
+ /// IEnumerator object of the Token ArrayList
+ public IEnumerator GetTokenEnumerator()
+ {
+ return m_alTokens.GetEnumerator();
+ }
+
+ ///
+ /// CheckMultiCharOps(): This function checks for multi character operations that together take
+ /// on a different meaning than simply by themselves. This can reorganize the entire ArrayList by the
+ /// time it is complete.
+ ///
+ private void CheckMultiCharOps()
+ {
+ ArrayList alTokens = new ArrayList();
+ IEnumerator iEnum = GetTokenEnumerator();
+ Token nextToken1 = null;
+ Token nextToken2 = null;
+
+ if (iEnum.MoveNext())
+ nextToken1 = (Token) iEnum.Current;
+
+ if (iEnum.MoveNext())
+ nextToken2 = (Token) iEnum.Current;
+
+ while (nextToken1 != null)
+ {
+ if (nextToken1.TokenType == CharType.CT_DELIM)
+ {
+ if (nextToken2 != null && nextToken2.TokenType == CharType.CT_DELIM)
+ {
+ string s1 = nextToken1.ToString() + nextToken2.ToString();
+
+ if (s1 == "&&" ||
+ s1 == "||" ||
+ s1 == "<=" ||
+ s1 == ">=" ||
+ s1 == "!=" ||
+ s1 == "<>" ||
+ s1 == "==")
+ {
+ nextToken1 = new Token(s1, CharType.CT_DELIM);
+
+ if (iEnum.MoveNext())
+ nextToken2 = (Token) iEnum.Current;
+ }
+ }
+ }
+
+ alTokens.Add(nextToken1);
+
+ nextToken1 = nextToken2;
+
+ if (nextToken2 != null)
+ {
+ if (iEnum.MoveNext())
+ nextToken2 = (Token) iEnum.Current;
+ else
+ nextToken2 = null;
+ }
+ else
+ nextToken1 = null;
+ }
+
+ m_alTokens = alTokens;
+ }
+
+ ///
+ /// Parse(): This function kicks off the parsing process of the provided function.
+ ///
+ private void Parse()
+ {
+ m_alTokens = new ArrayList();
+ CharType chType = CharType.CT_UNDEF;
+
+ string sToken = "";
+
+ CharEnumerator chEnum = m_sFunction.GetEnumerator();
+
+ while (chEnum.MoveNext())
+ {
+ if (m_sWhitespace.IndexOf(chEnum.Current) > -1)
+ {
+ if (sToken.Length > 0)
+ m_alTokens.Add(new Token(sToken, chType));
+ sToken = "";
+
+ continue;
+ }
+
+ if (m_sDelimiters.IndexOf(chEnum.Current) > -1)
+ {
+ if (sToken.Length > 0)
+ m_alTokens.Add(new Token(sToken, chType));
+
+ m_alTokens.Add(new Token(chEnum.Current, CharType.CT_DELIM));
+
+ sToken = "";
+ chType = CharType.CT_UNDEF;
+ continue;
+ }
+
+ if (m_sBrackets.IndexOf(chEnum.Current) > -1)
+ {
+ if (sToken.Length > 0)
+ m_alTokens.Add(new Token(sToken, chType));
+
+ m_alTokens.Add(new Token(chEnum.Current, CharType.CT_BRACKETS));
+
+ sToken = "";
+ chType = CharType.CT_UNDEF;
+ continue;
+ }
+
+ if (m_sNumbers.IndexOf(chEnum.Current) > -1)
+ {
+ if (sToken.Length == 0)
+ chType = CharType.CT_NUMBER;
+
+ sToken += chEnum.Current;
+ continue;
+ }
+
+ if (m_sLetters.IndexOf(chEnum.Current) > -1)
+ {
+ if (sToken.Length == 0)
+ chType = CharType.CT_LETTER;
+ else
+ {
+ if (chType != CharType.CT_LETTER)
+ chType = CharType.CT_UNDEF;
+ }
+ sToken += chEnum.Current;
+ continue;
+ }
+
+ if (sToken.Length > 0)
+ m_alTokens.Add(new Token(sToken, chType));
+
+ sToken = "";
+ chType = CharType.CT_UNDEF;
+ }
+
+ if (sToken.Length > 0)
+ m_alTokens.Add(new Token(sToken, chType));
+
+ CheckMultiCharOps();
+ }
+ }
+}
diff --git a/dotMath/Properties/AssemblyInfo.cs b/dotMath/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..dde0393
--- /dev/null
+++ b/dotMath/Properties/AssemblyInfo.cs
@@ -0,0 +1,35 @@
+using System.Reflection;
+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("dotMath Equation Compiler")]
+[assembly: AssemblyDescription("dotMath compiler library for algebraic equations")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Steve Hebert and Hebert Software Services, LLC")]
+[assembly: AssemblyProduct("dotMath")]
+[assembly: AssemblyCopyright("Copyright 2001-2004")]
+[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("0828FDE9-69DE-496E-90AA-1F9CCD050154")]
+
+// 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/dotMath/dotMath.csproj b/dotMath/dotMath.csproj
new file mode 100644
index 0000000..46c0f1f
--- /dev/null
+++ b/dotMath/dotMath.csproj
@@ -0,0 +1,127 @@
+
+
+
+ Local
+ 7.0.9466
+ 1.0
+ {B2EBEDE8-441A-4CC2-80FF-5F290D528919}
+ Debug
+ AnyCPU
+
+
+ dotMath
+
+ JScript
+ Grid
+ IE50
+ false
+ Library
+ dotMath
+
+
+
+ v2.0
+
+
+ 0.0
+ publish\
+ true
+ Disk
+ false
+ Foreground
+ 7
+ Days
+ false
+ false
+ true
+ 0
+ 1.0.0.%2a
+ false
+ false
+ true
+
+
+ bin\Debug\
+ false
+ 285212672
+ false
+
+ DEBUG;TRACE
+
+ true
+ 4096
+ false
+ false
+ false
+ false
+ 4
+ full
+ prompt
+
+
+ bin\Release\
+ false
+ 285212672
+ false
+
+ TRACE
+
+ false
+ 4096
+ true
+ false
+ false
+ false
+ 4
+ none
+ prompt
+
+
+
+ System
+
+
+ System.Configuration.Install
+
+
+ System.Data
+
+
+ System.Management
+
+
+ System.XML
+
+
+
+
+ Code
+
+
+ Code
+
+
+ Code
+
+
+ Code
+
+
+
+
+ False
+ .NET Framework 3.5 SP1 Client Profile
+ false
+
+
+ False
+ .NET Framework 3.5 SP1
+ true
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/packages/NUnit.2.6.3/NUnit.2.6.3.nupkg b/packages/NUnit.2.6.3/NUnit.2.6.3.nupkg
new file mode 100644
index 0000000..61e3a5e
Binary files /dev/null and b/packages/NUnit.2.6.3/NUnit.2.6.3.nupkg differ
diff --git a/packages/NUnit.2.6.3/lib/nunit.framework.dll b/packages/NUnit.2.6.3/lib/nunit.framework.dll
new file mode 100644
index 0000000..780727f
Binary files /dev/null and b/packages/NUnit.2.6.3/lib/nunit.framework.dll differ
diff --git a/packages/NUnit.2.6.3/lib/nunit.framework.xml b/packages/NUnit.2.6.3/lib/nunit.framework.xml
new file mode 100644
index 0000000..f40847c
--- /dev/null
+++ b/packages/NUnit.2.6.3/lib/nunit.framework.xml
@@ -0,0 +1,10960 @@
+
+
+
+ nunit.framework
+
+
+
+
+ The different targets a test action attribute can be applied to
+
+
+
+
+ Default target, which is determined by where the action attribute is attached
+
+
+
+
+ Target a individual test case
+
+
+
+
+ Target a suite of test cases
+
+
+
+
+ Delegate used by tests that execute code and
+ capture any thrown exception.
+
+
+
+
+ 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.
+
+
+
+
+
+
+ Throws a with the message and arguments
+ that are passed in. This allows a test to be cut short, with a result
+ of success returned to NUnit.
+
+ The message to initialize the with.
+ Arguments to be used in formatting the message
+
+
+
+ Throws a with the message and arguments
+ that are passed in. This allows a test to be cut short, with a result
+ of success returned to NUnit.
+
+ The message to initialize the with.
+
+
+
+ Throws a with the message and arguments
+ that are passed in. This allows a test to be cut short, with a result
+ of success returned to NUnit.
+
+
+
+
+ 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.
+
+
+
+
+ Throws an with the message and arguments
+ that are passed in. This causes the test to be reported as inconclusive.
+
+ 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 inconclusive.
+
+ The message to initialize the with.
+
+
+
+ Throws an .
+ This causes the test to be reported as Inconclusive.
+
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+ 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.
+
+ The actual value to test
+ A Constraint expression to be applied
+ 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
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ An ActualValueDelegate returning the value to be tested
+ A Constraint expression to be applied
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ An ActualValueDelegate returning the value to be tested
+ A Constraint expression to be applied
+ 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.
+
+ An ActualValueDelegate returning the value to be tested
+ A Constraint expression to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the code represented by a delegate throws an exception
+ that satisfies the constraint provided.
+
+ A TestDelegate to be executed
+ A ThrowsConstraint used in the test
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+ Used as a synonym for That in rare cases where a private setter
+ causes a Visual Basic compilation error.
+
+ The actual value to test
+ A Constraint to be applied
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+ Used as a synonym for That in rare cases where a private setter
+ causes a Visual Basic compilation error.
+
+ The actual value to test
+ A Constraint to be applied
+ 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.
+ Used as a synonym for That in rare cases where a private setter
+ causes a Visual Basic compilation error.
+
+
+ This method is provided for use by VB developers needing to test
+ the value of properties with private setters.
+
+ The actual value to test
+ A Constraint expression to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ A constraint to be satisfied by the exception
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ A constraint to be satisfied by the exception
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ A constraint to be satisfied by the exception
+ A TestDelegate
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ The exception Type expected
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ The exception Type expected
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ The exception Type expected
+ A TestDelegate
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ Type of the expected exception
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ Type of the expected exception
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws a particular exception when called.
+
+ Type of the expected exception
+ A TestDelegate
+
+
+
+ Verifies that a delegate throws an exception when called
+ and returns it.
+
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws an exception when called
+ and returns it.
+
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws an exception when called
+ and returns it.
+
+ A TestDelegate
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate throws an exception of a certain Type
+ or one derived from it when called and returns it.
+
+ The expected Exception Type
+ A TestDelegate
+
+
+
+ Verifies that a delegate does not throw an exception
+
+ A TestDelegate
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that a delegate does not throw an exception.
+
+ A TestDelegate
+ The message that will be displayed on failure
+
+
+
+ Verifies that a delegate does not throw an exception.
+
+ A TestDelegate
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display in case of failure
+ Array of objects 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 in case of failure
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+
+
+
+ Asserts that a condition is true. If the condition is false the method throws
+ an .
+
+ The evaluated condition
+ The message to display in case of failure
+ Array of objects 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 in case of failure
+
+
+
+ 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 in case of failure
+ Array of objects 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 in case of failure
+
+
+
+ Asserts that a condition is false. If the condition is true 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 in case of failure
+ Array of objects 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 in case of failure
+
+
+
+ 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 display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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 not equal to null
+ If the object is null
then an
+ is thrown.
+
+ The object that is to be tested
+ The message to display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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 display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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
+
+
+
+ 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 display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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
+
+
+
+ Verifies that two ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of failure
+
+
+
+ Verifies that two longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two unsigned ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two unsigned ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two unsigned ints are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two unsigned longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two unsigned longs are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two unsigned longs 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 to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two decimals are equal. If they are not, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of 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 equal then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message to display in case of failure
+ Array of objects 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 equal then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message to display in case of 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 equal then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+
+
+
+ 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 equal then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message to display in case of failure
+ Array of objects 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 equal then an is
+ thrown.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message to display in case of 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 equal 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. NUnit
+ has special semantics for some object types.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display in case of failure
+ Array of objects 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. NUnit
+ has special semantics for some object types.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two objects are equal. Two objects are considered
+ equal if both are null, or if both have the same value. NUnit
+ has special semantics for some object types.
+ If they are not equal an is thrown.
+
+ The value that is expected
+ The actual value
+
+
+
+ Verifies that two ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two unsigned ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two unsigned ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two unsigned ints are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two unsigned longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two unsigned longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two unsigned longs are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two decimals are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two decimals are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two decimals are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two floats are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two floats are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two floats are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two doubles are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two doubles are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two doubles are not equal. If they are equal, then an
+ is thrown.
+
+ The expected value
+ The actual value
+
+
+
+ Verifies that two objects are not equal. Two objects are considered
+ equal if both are null, or if both have the same value. NUnit
+ has special semantics for some object types.
+ If they are equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that two objects are not equal. Two objects are considered
+ equal if both are null, or if both have the same value. NUnit
+ has special semantics for some object types.
+ If they are equal an is thrown.
+
+ The value that is expected
+ The actual value
+ The message to display in case of failure
+
+
+
+ Verifies that two objects are not equal. Two objects are considered
+ equal if both are null, or if both have the same value. NUnit
+ has special semantics for some object types.
+ If they are equal an is thrown.
+
+ The value that is expected
+ The actual value
+
+
+
+ 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 display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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 display in case of failure
+ Array of objects 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 display in case of failure
+
+
+
+ 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 double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+ The message to display in case of failure
+
+
+
+ Verifies that the double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+
+
+
+ Verifies that the double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value that is to be tested
+ The message to display in case of failure
+
+
+
+ Verifies that the double that is passed in is an NaN
value.
+ If the object is not NaN
then an
+ is thrown.
+
+ The value 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 display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Assert that a string is empty - that is equal to string.Empty
+
+ The string to be tested
+ The message to display in case of failure
+
+
+
+ Assert that a string is empty - that is equal to string.Empty
+
+ 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 display in case of failure
+ Array of objects 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 display in case of 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 display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Assert that a string is not empty - that is not equal to string.Empty
+
+ The string to be tested
+ The message to display in case of failure
+
+
+
+ Assert that a string is not empty - that is not equal to string.Empty
+
+ The string to be tested
+
+
+
+ Assert that an array, list or other collection is not empty
+
+ An array, list or other collection implementing ICollection
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is not empty
+
+ An array, list or other collection implementing ICollection
+ The message to display in case of failure
+
+
+
+ Assert that an array, list or other collection is not empty
+
+ An array, list or other collection implementing ICollection
+
+
+
+ Assert that a string is either null or equal to string.Empty
+
+ The string to be tested
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Assert that a string is either null or equal to string.Empty
+
+ The string to be tested
+ The message to display in case of failure
+
+
+
+ Assert that a string is either null or equal to string.Empty
+
+ The string to be tested
+
+
+
+ Assert that a string is not null or empty
+
+ The string to be tested
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Assert that a string is not null or empty
+
+ The string to be tested
+ The message to display in case of failure
+
+
+
+ Assert that a string is not null or empty
+
+ The string to be tested
+
+
+
+ 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 be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The message 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
+
+
+
+ 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 be assigned a value of a given Type.
+
+ The expected Type.
+ The object under examination
+ The message 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
+
+
+
+ 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 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
+
+
+
+ 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 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
+ The message 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
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+ 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
+ The 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
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+ 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
+ The 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
+
+
+
+ Asserts that an object is an instance of a given type.
+
+ The expected Type
+ The object being examined
+ 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
+ The 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
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+ The message to display in case of failure
+ 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
+ The 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
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+ The message to display in case of failure
+ 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
+ The 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
+
+
+
+ Asserts that an object is not an instance of a given type.
+
+ The expected Type
+ The object being examined
+ The message to display in case of failure
+ 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
+ The 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
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than the second
+ value. If it is 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is not, then an
+ is thrown.
+
+ The first value, expected to be greater
+ The second value, expected to be less
+ The message to display in case of failure
+
+
+
+ Verifies that the first value is greater than or equal tothe second
+ value. If it is 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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 to display in case of failure
+ Array of objects 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 to display in case of 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
+
+
+
+ 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
+ Array of objects to be 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
+
+
+
+ Helper for Assert.AreEqual(double expected, double actual, ...)
+ allowing code generation to work consistently.
+
+ The expected value
+ The actual value
+ The maximum acceptable difference between the
+ the expected and the actual
+ The message to display in case of failure
+ Array of objects to be used in formatting the message
+
+
+
+ Gets the number of assertions executed so far and
+ resets the counter to zero.
+
+
+
+
+ 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.
+
+
+
+
+ Helper class with properties and methods that supply
+ a number of constraints used in Asserts.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding only if a specified number of them succeed.
+
+
+
+
+ Returns a new PropertyConstraintExpression, which will either
+ test for the existence of the named property on the object
+ being tested or apply any following constraint to that property.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns a constraint that tests two items for equality
+
+
+
+
+ Returns a constraint that tests that two references are the same object
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a collection containing the same elements as the
+ collection supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a subset of the collection supplied as an argument.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a new ContainsConstraint. This constraint
+ will, in turn, make use of the appropriate second-level
+ constraint, depending on the type of the actual argument.
+ This overload is only used if the item sought is a string,
+ since any other type implies that we are looking for a
+ collection member.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the regular expression supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the regular expression supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value matches the pattern supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same as an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same path or under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same path or under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the actual value falls
+ within a specified range.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if at least one of them succeeds.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them fail.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Length property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Count property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Message property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the InnerException property of the object being tested.
+
+
+
+
+ Returns a constraint that tests for null
+
+
+
+
+ Returns a constraint that tests for True
+
+
+
+
+ Returns a constraint that tests for False
+
+
+
+
+ Returns a constraint that tests for a positive value
+
+
+
+
+ Returns a constraint that tests for a negative value
+
+
+
+
+ Returns a constraint that tests for NaN
+
+
+
+
+ Returns a constraint that tests for empty
+
+
+
+
+ Returns a constraint that tests whether a collection
+ contains all unique items.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in binary format.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in xml format.
+
+
+
+
+ Returns a constraint that tests whether a collection is ordered
+
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to Assert.That.
+
+ The actual value to test
+ A Constraint to be applied
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to Assert.That.
+
+ The actual value to test
+ A Constraint to be applied
+ The message to be displayed in case of failure
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure. Works
+ identically to Assert.That.
+
+ The actual value to test
+ A Constraint to be applied
+ The message to be displayed in case of failure
+ Arguments to use 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
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ A Constraint expression to be applied
+ An ActualValueDelegate returning the value to be tested
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ A Constraint expression to be applied
+ An ActualValueDelegate returning the value to be tested
+ 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.
+
+ An ActualValueDelegate returning the value to be tested
+ A Constraint expression to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an assertion exception on failure.
+
+ The actual value to test
+ A Constraint to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the code represented by a delegate throws an exception
+ that satisfies the constraint provided.
+
+ A TestDelegate to be executed
+ A ThrowsConstraint used in the test
+
+
+
+ Returns a ListMapper based on a collection.
+
+ The original collection
+
+
+
+
+ Provides static methods to express the assumptions
+ that must be met for a test to give a meaningful
+ result. If an assumption is not met, the test
+ should produce an inconclusive result.
+
+
+
+
+ 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.
+
+
+
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression to be applied
+ The actual value to test
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression 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 InconclusiveException on failure.
+
+ A Constraint expression 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
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression to be applied
+ An ActualValueDelegate returning the value to be tested
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression to be applied
+ An ActualValueDelegate returning the value to be tested
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to an actual value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ An ActualValueDelegate returning the value to be tested
+ A Constraint expression to be applied
+ The message that will be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression to be applied
+ The actual value to test
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression to be applied
+ The actual value to test
+ The message that will be displayed on failure
+
+
+
+ Apply a constraint to a referenced value, succeeding if the constraint
+ is satisfied and throwing an InconclusiveException on failure.
+
+ A Constraint expression 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 the code represented by a delegate throws an exception
+ that satisfies the constraint provided.
+
+ A TestDelegate to be executed
+ A ThrowsConstraint used in the test
+
+
+
+ Waits for pending asynchronous operations to complete, if appropriate,
+ and returns a proper result of the invocation by unwrapping task results
+
+ The raw result of the method invocation
+ The unwrapped result, if necessary
+
+
+
+ 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
+
+
+
+ Assert that an array, list or other collection is ordered
+
+ 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 ordered
+
+ An array, list or other collection implementing IEnumerable
+ The message to be displayed on failure
+
+
+
+ Assert that an array, list or other collection is ordered
+
+ An array, list or other collection implementing IEnumerable
+
+
+
+ Assert that an array, list or other collection is ordered
+
+ An array, list or other collection implementing IEnumerable
+ A custom comparer to perform the comparisons
+ The message to be displayed on failure
+ Arguments to be used in formatting the message
+
+
+
+ Assert that an array, list or other collection is ordered
+
+ An array, list or other collection implementing IEnumerable
+ A custom comparer to perform the comparisons
+ The message to be displayed on failure
+
+
+
+ Assert that an array, list or other collection is ordered
+
+ An array, list or other collection implementing IEnumerable
+ A custom comparer to perform the comparisons
+
+
+
+ Helper class with properties and methods that supply
+ a number of constraints used in Asserts.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Summary description for DirectoryAssert
+
+
+
+
+ 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 directories are equal. Two directories 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 directory containing the value that is expected
+ A directory containing the actual value
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two directories are equal. Two directories 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 directory containing the value that is expected
+ A directory containing the actual value
+ The message to display if directories are not equal
+
+
+
+ Verifies that two directories are equal. Two directories 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 directory containing the value that is expected
+ A directory containing the actual value
+
+
+
+ Verifies that two directories are equal. Two directories 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 directory path string containing the value that is expected
+ A directory path string containing the actual value
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Verifies that two directories are equal. Two directories 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 directory path string containing the value that is expected
+ A directory path string containing the actual value
+ The message to display if directories are not equal
+
+
+
+ Verifies that two directories are equal. Two directories 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 directory path string containing the value that is expected
+ A directory path string containing the actual value
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory containing the value that is expected
+ A directory containing the actual value
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory containing the value that is expected
+ A directory containing the actual value
+ The message to display if directories are not equal
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory containing the value that is expected
+ A directory containing the actual value
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory path string containing the value that is expected
+ A directory path string containing the actual value
+ The message to display if directories are equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory path string containing the value that is expected
+ A directory path string containing the actual value
+ The message to display if directories are equal
+
+
+
+ Asserts that two directories are not equal. If they are equal
+ an is thrown.
+
+ A directory path string containing the value that is expected
+ A directory path string containing the actual value
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+
+
+
+ Asserts that the directory is empty. If it is not empty
+ an is thrown.
+
+ A directory to search
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+ The message to display if directories are not equal
+
+
+
+ Asserts that the directory is not empty. If it is empty
+ an is thrown.
+
+ A directory to search
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+
+
+
+ Asserts that path contains actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+ Arguments to be used in formatting the message
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+ The message to display if directory is not within the path
+
+
+
+ Asserts that path does not contain actual as a subdirectory or
+ an is thrown.
+
+ A directory to search
+ sub-directory asserted to exist under directory
+
+
+
+ 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
+
+
+
+ GlobalSettings is a place for setting default values used
+ by the framework in performing asserts.
+
+
+
+
+ Default tolerance for floating point equality
+
+
+
+
+ Class used to guard against unexpected argument values
+ by throwing an appropriate exception.
+
+
+
+
+ Throws an exception if an argument is null
+
+ The value to be tested
+ The name of the argument
+
+
+
+ Throws an exception if a string argument is null or empty
+
+ The value to be tested
+ The name of the argument
+
+
+
+ Helper class with properties and methods that supply
+ a number of constraints used in Asserts.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding only if a specified number of them succeed.
+
+
+
+
+ Returns a new PropertyConstraintExpression, which will either
+ test for the existence of the named property on the object
+ being tested or apply any following constraint to that property.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if at least one of them succeeds.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them fail.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Length property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Count property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Message property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the InnerException property of the object being tested.
+
+
+
+
+ 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
+
+
+
+ Helper class with properties and methods that supply
+ a number of constraints used in Asserts.
+
+
+
+
+ Returns a constraint that tests two items for equality
+
+
+
+
+ Returns a constraint that tests that two references are the same object
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a collection containing the same elements as the
+ collection supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a subset of the collection supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the regular expression supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same as an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same path or under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the actual value falls
+ within a specified range.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ Returns a constraint that tests for null
+
+
+
+
+ Returns a constraint that tests for True
+
+
+
+
+ Returns a constraint that tests for False
+
+
+
+
+ Returns a constraint that tests for a positive value
+
+
+
+
+ Returns a constraint that tests for a negative value
+
+
+
+
+ Returns a constraint that tests for NaN
+
+
+
+
+ Returns a constraint that tests for empty
+
+
+
+
+ Returns a constraint that tests whether a collection
+ contains all unique items.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in binary format.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in xml format.
+
+
+
+
+ Returns a constraint that tests whether a collection is ordered
+
+
+
+
+ The ITestCaseData interface is implemented by a class
+ that is able to return complete testcases for use by
+ a parameterized test method.
+
+ NOTE: This interface is used in both the framework
+ and the core, even though that results in two different
+ types. However, sharing the source code guarantees that
+ the various implementations will be compatible and that
+ the core is able to reflect successfully over the
+ framework implementations of ITestCaseData.
+
+
+
+
+ Gets the argument list to be provided to the test
+
+
+
+
+ Gets the expected result
+
+
+
+
+ Indicates whether a result has been specified.
+ This is necessary because the result may be
+ null, so it's value cannot be checked.
+
+
+
+
+ Gets the expected exception Type
+
+
+
+
+ Gets the FullName of the expected exception
+
+
+
+
+ Gets the name to be used for the test
+
+
+
+
+ Gets the description of the test
+
+
+
+
+ Gets a value indicating whether this is ignored.
+
+ true if ignored; otherwise, false.
+
+
+
+ Gets a value indicating whether this is explicit.
+
+ true if explicit; otherwise, false.
+
+
+
+ Gets the ignore reason.
+
+ The ignore reason.
+
+
+
+ The Iz class is a synonym for Is intended for use in VB,
+ which regards Is as a keyword.
+
+
+
+
+ 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
+
+
+
+
+ Randomizer returns a set of random values in a repeatable
+ way, to allow re-running of tests if necessary.
+
+
+
+
+ Get a randomizer for a particular member, returning
+ one that has already been created if it exists.
+ This ensures that the same values are generated
+ each time the tests are reloaded.
+
+
+
+
+ Get a randomizer for a particular parameter, returning
+ one that has already been created if it exists.
+ This ensures that the same values are generated
+ each time the tests are reloaded.
+
+
+
+
+ Construct a randomizer using a random seed
+
+
+
+
+ Construct a randomizer using a specified seed
+
+
+
+
+ Return an array of random doubles between 0.0 and 1.0.
+
+
+
+
+
+
+ Return an array of random doubles with values in a specified range.
+
+
+
+
+ Return an array of random ints with values in a specified range.
+
+
+
+
+ Get a random seed for use in creating a randomizer.
+
+
+
+
+ The SpecialValue enum is used to represent TestCase arguments
+ that cannot be used as arguments to an Attribute.
+
+
+
+
+ Null represents a null value, which cannot be used as an
+ argument to an attribute under .NET 1.x
+
+
+
+
+ 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 is not 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 does not start 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 does not start with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that a string does not start 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 a string does not end 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 does not end with another string.
+
+ The expected string
+ The string to be examined
+ The message to display in case of failure
+
+
+
+ Asserts that a string does not end 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 two strings are not 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 Notequal, without regard to case.
+
+ The expected string
+ The actual string
+ The message to display in case of failure
+
+
+
+ Asserts that two strings are not equal, without regard to case.
+
+ The expected string
+ The actual string
+
+
+
+ Asserts that a string matches an expected regular expression pattern.
+
+ The regex pattern to be matched
+ 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 regex pattern to be matched
+ The actual string
+ The message to display in case of failure
+
+
+
+ Asserts that a string matches an expected regular expression pattern.
+
+ The regex pattern to be matched
+ The actual string
+
+
+
+ Asserts that a string does not match an expected regular expression pattern.
+
+ The regex pattern to be used
+ The actual string
+ The message to display in case of failure
+ Arguments used in formatting the message
+
+
+
+ Asserts that a string does not match an expected regular expression pattern.
+
+ The regex pattern to be used
+ The actual string
+ The message to display in case of failure
+
+
+
+ Asserts that a string does not match an expected regular expression pattern.
+
+ The regex pattern to be used
+ The actual string
+
+
+
+ The TestCaseData class represents a set of arguments
+ and other parameter info to be used for a parameterized
+ test case. It provides a number of instance modifiers
+ for use in initializing the test case.
+
+ Note: Instance modifiers are getters that return
+ the same instance after modifying it's state.
+
+
+
+
+ The argument list to be provided to the test
+
+
+
+
+ The expected result to be returned
+
+
+
+
+ Set to true if this has an expected result
+
+
+
+
+ The expected exception Type
+
+
+
+
+ The FullName of the expected exception
+
+
+
+
+ The name to be used for the test
+
+
+
+
+ The description of the test
+
+
+
+
+ A dictionary of properties, used to add information
+ to tests without requiring the class to change.
+
+
+
+
+ If true, indicates that the test case is to be ignored
+
+
+
+
+ If true, indicates that the test case is marked explicit
+
+
+
+
+ The reason for ignoring a test case
+
+
+
+
+ Initializes a new instance of the class.
+
+ The arguments.
+
+
+
+ Initializes a new instance of the class.
+
+ The argument.
+
+
+
+ Initializes a new instance of the class.
+
+ The first argument.
+ The second argument.
+
+
+
+ Initializes a new instance of the class.
+
+ The first argument.
+ The second argument.
+ The third argument.
+
+
+
+ Sets the expected result for the test
+
+ The expected result
+ A modified TestCaseData
+
+
+
+ Sets the expected exception type for the test
+
+ Type of the expected exception.
+ The modified TestCaseData instance
+
+
+
+ Sets the expected exception type for the test
+
+ FullName of the expected exception.
+ The modified TestCaseData instance
+
+
+
+ Sets the name of the test case
+
+ The modified TestCaseData instance
+
+
+
+ Sets the description for the test case
+ being constructed.
+
+ The description.
+ The modified TestCaseData instance.
+
+
+
+ Applies a category to the test
+
+
+
+
+
+
+ Applies a named property to the test
+
+
+
+
+
+
+
+ Applies a named property to the test
+
+
+
+
+
+
+
+ Applies a named property to the test
+
+
+
+
+
+
+
+ Ignores this TestCase.
+
+
+
+
+
+ Ignores this TestCase, specifying the reason.
+
+ The reason.
+
+
+
+
+ Marks this TestCase as Explicit
+
+
+
+
+
+ Marks this TestCase as Explicit, specifying the reason.
+
+ The reason.
+
+
+
+
+ Gets the argument list to be provided to the test
+
+
+
+
+ Gets the expected result
+
+
+
+
+ Returns true if the result has been set
+
+
+
+
+ Gets the expected exception Type
+
+
+
+
+ Gets the FullName of the expected exception
+
+
+
+
+ Gets the name to be used for the test
+
+
+
+
+ Gets the description of the test
+
+
+
+
+ Gets a value indicating whether this is ignored.
+
+ true if ignored; otherwise, false.
+
+
+
+ Gets a value indicating whether this is explicit.
+
+ true if explicit; otherwise, false.
+
+
+
+ Gets the ignore reason.
+
+ The ignore reason.
+
+
+
+ Gets a list of categories associated with this test.
+
+
+
+
+ Gets the property dictionary for this test
+
+
+
+
+ Provide the context information of the current test
+
+
+
+
+ Constructs a TestContext using the provided context dictionary
+
+ A context dictionary
+
+
+
+ Get the current test context. This is created
+ as needed. The user may save the context for
+ use within a test, but it should not be used
+ outside the test for which it is created.
+
+
+
+
+ Gets a TestAdapter representing the currently executing test in this context.
+
+
+
+
+ Gets a ResultAdapter representing the current result for the test
+ executing in this context.
+
+
+
+
+ Gets the directory containing the current test assembly.
+
+
+
+
+ Gets the directory to be used for outputing files created
+ by this test run.
+
+
+
+
+ TestAdapter adapts a Test for consumption by
+ the user test code.
+
+
+
+
+ Constructs a TestAdapter for this context
+
+ The context dictionary
+
+
+
+ The name of the test.
+
+
+
+
+ The FullName of the test
+
+
+
+
+ The properties of the test.
+
+
+
+
+ ResultAdapter adapts a TestResult for consumption by
+ the user test code.
+
+
+
+
+ Construct a ResultAdapter for a context
+
+ The context holding the result
+
+
+
+ The TestState of current test. This maps to the ResultState
+ used in nunit.core and is subject to change in the future.
+
+
+
+
+ The TestStatus of current test. This enum will be used
+ in future versions of NUnit and so is to be preferred
+ to the TestState value.
+
+
+
+
+ Provides details about a test
+
+
+
+
+ Creates an instance of TestDetails
+
+ The fixture that the test is a member of, if available.
+ The method that implements the test, if available.
+ The full name of the test.
+ A string representing the type of test, e.g. "Test Case".
+ Indicates if the test represents a suite of tests.
+
+
+
+ The fixture that the test is a member of, if available.
+
+
+
+
+ The method that implements the test, if available.
+
+
+
+
+ The full name of the test.
+
+
+
+
+ A string representing the type of test, e.g. "Test Case".
+
+
+
+
+ Indicates if the test represents a suite of tests.
+
+
+
+
+ The ResultState enum indicates the result of running a test
+
+
+
+
+ The result is inconclusive
+
+
+
+
+ The test was not runnable.
+
+
+
+
+ The test has been skipped.
+
+
+
+
+ The test has been ignored.
+
+
+
+
+ The test succeeded
+
+
+
+
+ The test failed
+
+
+
+
+ The test encountered an unexpected exception
+
+
+
+
+ The test was cancelled by the user
+
+
+
+
+ The TestStatus enum indicates the result of running a test
+
+
+
+
+ The test was inconclusive
+
+
+
+
+ The test has skipped
+
+
+
+
+ The test succeeded
+
+
+
+
+ The test failed
+
+
+
+
+ Helper class with static methods used to supply constraints
+ that operate on strings.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the Regex pattern supplied as an argument.
+
+
+
+
+ Returns a constraint that fails if the actual
+ value matches the pattern supplied as an argument.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ 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.
+
+
+
+
+ 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
+
+
+
+
+ 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
+
+
+
+
+ Helper class with properties and methods that supply
+ constraints that operate on exceptions.
+
+
+
+
+ Creates a constraint specifying the exact type of exception expected
+
+
+
+
+ Creates a constraint specifying the exact type of exception expected
+
+
+
+
+ Creates a constraint specifying the type of exception expected
+
+
+
+
+ Creates a constraint specifying the type of exception expected
+
+
+
+
+ Creates a constraint specifying an expected exception
+
+
+
+
+ Creates a constraint specifying an exception with a given InnerException
+
+
+
+
+ Creates a constraint specifying an expected TargetInvocationException
+
+
+
+
+ Creates a constraint specifying an expected TargetInvocationException
+
+
+
+
+ Creates a constraint specifying an expected TargetInvocationException
+
+
+
+
+ Creates a constraint specifying that no exception is thrown
+
+
+
+
+ Attribute used to apply a category to a test
+
+
+
+
+ The name of the category
+
+
+
+
+ Construct attribute for a given category based on
+ a name. The name may not contain the characters ',',
+ '+', '-' or '!'. However, this is not checked in the
+ constructor since it would cause an error to arise at
+ as the test was loaded without giving a clear indication
+ of where the problem is located. The error is handled
+ in NUnitFramework.cs by marking the test as not
+ runnable.
+
+ The name of the category
+
+
+
+ Protected constructor uses the Type name as the name
+ of the category.
+
+
+
+
+ The name of the category
+
+
+
+
+ Used to mark a field for use as a datapoint when executing a theory
+ within the same fixture that requires an argument of the field's Type.
+
+
+
+
+ Used to mark an array as containing a set of datapoints to be used
+ executing a theory within the same fixture that requires an argument
+ of the Type of the array elements.
+
+
+
+
+ Attribute used to provide descriptive text about a
+ test case or fixture.
+
+
+
+
+ Construct the attribute
+
+ Text describing the test
+
+
+
+ Gets the test description
+
+
+
+
+ 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
+
+
+ Expect a message that starts with the parameter string
+
+
+
+ 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
+
+
+
+ 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
+
+
+
+
+ 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 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
+
+
+
+
+ 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
+
+
+
+ Marks a test to use a combinatorial join of any argument data
+ provided. NUnit will create a test case for every combination of
+ the arguments provided. This can result in a large number of test
+ cases and so should be used judiciously. This is the default join
+ type, so the attribute need not be used except as documentation.
+
+
+
+
+ PropertyAttribute is used to attach information to a test as a name/value pair..
+
+
+
+
+ Construct a PropertyAttribute with a name and string value
+
+ The name of the property
+ The property value
+
+
+
+ Construct a PropertyAttribute with a name and int value
+
+ The name of the property
+ The property value
+
+
+
+ Construct a PropertyAttribute with a name and double value
+
+ The name of the property
+ The property value
+
+
+
+ Constructor for derived classes that set the
+ property dictionary directly.
+
+
+
+
+ Constructor for use by derived classes that use the
+ name of the type as the property name. Derived classes
+ must ensure that the Type of the property value is
+ a standard type supported by the BCL. Any custom
+ types will cause a serialization Exception when
+ in the client.
+
+
+
+
+ Gets the property dictionary for this attribute
+
+
+
+
+ Default constructor
+
+
+
+
+ Marks a test to use pairwise join of any argument data provided.
+ NUnit will attempt too excercise every pair of argument values at
+ least once, using as small a number of test cases as it can. With
+ only two arguments, this is the same as a combinatorial join.
+
+
+
+
+ Default constructor
+
+
+
+
+ Marks a test to use a sequential join of any argument data
+ provided. NUnit will use arguements for each parameter in
+ sequence, generating test cases up to the largest number
+ of argument values provided and using null for any arguments
+ for which it runs out of values. Normally, this should be
+ used with the same number of arguments for each parameter.
+
+
+
+
+ Default constructor
+
+
+
+
+ Summary description for MaxTimeAttribute.
+
+
+
+
+ Construct a MaxTimeAttribute, given a time in milliseconds.
+
+ The maximum elapsed time in milliseconds
+
+
+
+ RandomAttribute is used to supply a set of random values
+ to a single parameter of a parameterized test.
+
+
+
+
+ ValuesAttribute is used to provide literal arguments for
+ an individual parameter of a test.
+
+
+
+
+ Abstract base class for attributes that apply to parameters
+ and supply data for the parameter.
+
+
+
+
+ Gets the data to be provided to the specified parameter
+
+
+
+
+ The collection of data to be returned. Must
+ be set by any derived attribute classes.
+ We use an object[] so that the individual
+ elements may have their type changed in GetData
+ if necessary.
+
+
+
+
+ Construct with one argument
+
+
+
+
+
+ Construct with two arguments
+
+
+
+
+
+
+ Construct with three arguments
+
+
+
+
+
+
+
+ Construct with an array of arguments
+
+
+
+
+
+ Get the collection of values to be used as arguments
+
+
+
+
+ Construct a set of doubles from 0.0 to 1.0,
+ specifying only the count.
+
+
+
+
+
+ Construct a set of doubles from min to max
+
+
+
+
+
+
+
+ Construct a set of ints from min to max
+
+
+
+
+
+
+
+ Get the collection of values to be used as arguments
+
+
+
+
+ RangeAttribute is used to supply a range of values to an
+ individual parameter of a parameterized test.
+
+
+
+
+ Construct a range of ints using default step of 1
+
+
+
+
+
+
+ Construct a range of ints specifying the step size
+
+
+
+
+
+
+
+ Construct a range of longs
+
+
+
+
+
+
+
+ Construct a range of doubles
+
+
+
+
+
+
+
+ Construct a range of floats
+
+
+
+
+
+
+
+ RepeatAttribute may be applied to test case in order
+ to run it multiple times.
+
+
+
+
+ Construct a RepeatAttribute
+
+ The number of times to run the test
+
+
+
+ RequiredAddinAttribute may be used to indicate the names of any addins
+ that must be present in order to run some or all of the tests in an
+ assembly. If the addin is not loaded, the entire assembly is marked
+ as NotRunnable.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The required addin.
+
+
+
+ Gets the name of required addin.
+
+ The required addin name.
+
+
+
+ Summary description for SetCultureAttribute.
+
+
+
+
+ Construct given the name of a culture
+
+
+
+
+
+ Summary description for SetUICultureAttribute.
+
+
+
+
+ Construct given the name of a culture
+
+
+
+
+
+ SetUpAttribute is used in a TestFixture to identify a method
+ that is called immediately before each test is run. It is
+ also used in a SetUpFixture to identify the method that is
+ called once, before any of the subordinate tests are run.
+
+
+
+
+ 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.
+
+
+
+
+ Attribute used to mark a static (shared in VB) property
+ that returns a list of tests.
+
+
+
+
+ Attribute used in a TestFixture to identify a method that is
+ called immediately after each test is run. It is also used
+ in a SetUpFixture to identify the method that is called once,
+ after all subordinate tests have run. In either case, the method
+ is guaranteed to be called, even if an exception is thrown.
+
+
+
+
+ Provide actions to execute before and after tests.
+
+
+
+
+ When implemented by an attribute, this interface implemented to provide actions to execute before and after tests.
+
+
+
+
+ Executed before each test is run
+
+ Provides details about the test that is going to be run.
+
+
+
+ Executed after each test is run
+
+ Provides details about the test that has just been run.
+
+
+
+ Provides the target for the action attribute
+
+ The target for the action attribute
+
+
+
+ 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
+
+
+
+
+ TestCaseAttribute is used to mark parameterized test cases
+ and provide them with their arguments.
+
+
+
+
+ Construct a TestCaseAttribute with a list of arguments.
+ This constructor is not CLS-Compliant
+
+
+
+
+
+ Construct a TestCaseAttribute with a single argument
+
+
+
+
+
+ Construct a TestCaseAttribute with a two arguments
+
+
+
+
+
+
+ Construct a TestCaseAttribute with a three arguments
+
+
+
+
+
+
+
+ Gets the list of arguments to a test case
+
+
+
+
+ Gets or sets the expected result. Use
+ ExpectedResult by preference.
+
+ The result.
+
+
+
+ Gets or sets the expected result.
+
+ The result.
+
+
+
+ Gets a flag indicating whether an expected
+ result has been set.
+
+
+
+
+ Gets a list of categories associated with this test;
+
+
+
+
+ Gets or sets the category associated with this test.
+ May be a single category or a comma-separated list.
+
+
+
+
+ Gets or sets the expected exception.
+
+ The expected exception.
+
+
+
+ Gets or sets the name the expected exception.
+
+ The expected name of the exception.
+
+
+
+ Gets or sets the expected message of the expected exception
+
+ The expected message of the exception.
+
+
+
+ Gets or sets the type of match to be performed on the expected message
+
+
+
+
+ Gets or sets the description.
+
+ The description.
+
+
+
+ Gets or sets the name of the test.
+
+ The name of the test.
+
+
+
+ Gets or sets the ignored status of the test
+
+
+
+
+ Gets or sets the ignored status of the test
+
+
+
+
+ Gets or sets the explicit status of the test
+
+
+
+
+ Gets or sets the reason for not running the test
+
+
+
+
+ Gets or sets the reason for not running the test.
+ Set has the side effect of marking the test as ignored.
+
+ The ignore reason.
+
+
+
+ FactoryAttribute indicates the source to be used to
+ provide test cases for a test method.
+
+
+
+
+ Construct with the name of the data source, which must
+ be a property, field or method of the test class itself.
+
+ An array of the names of the factories that will provide data
+
+
+
+ Construct with a Type, which must implement IEnumerable
+
+ The Type that will provide data
+
+
+
+ Construct with a Type and name.
+ that don't support params arrays.
+
+ The Type that will provide data
+ The name of the method, property or field that will provide data
+
+
+
+ The name of a the method, property or fiend to be used as a source
+
+
+
+
+ A Type to be used as a source
+
+
+
+
+ Gets or sets the category associated with this test.
+ May be a single category or a comma-separated list.
+
+
+
+
+ [TestFixture]
+ public class ExampleClass
+ {}
+
+
+
+
+ Default constructor
+
+
+
+
+ Construct with a object[] representing a set of arguments.
+ In .NET 2.0, the arguments may later be separated into
+ type arguments and constructor arguments.
+
+
+
+
+
+ Descriptive text for this fixture
+
+
+
+
+ Gets and sets the category for this fixture.
+ May be a comma-separated list of categories.
+
+
+
+
+ Gets a list of categories for this fixture
+
+
+
+
+ The arguments originally provided to the attribute
+
+
+
+
+ Gets or sets a value indicating whether this should be ignored.
+
+ true if ignore; otherwise, false.
+
+
+
+ Gets or sets the ignore reason. May set Ignored as a side effect.
+
+ The ignore reason.
+
+
+
+ Get or set the type arguments. If not set
+ explicitly, any leading arguments that are
+ Types are taken as type arguments.
+
+
+
+
+ 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.
+
+
+
+
+ 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()
+ {}
+ }
+
+
+
+
+
+ Used on a method, marks the test with a timeout value in milliseconds.
+ The test will be run in a separate thread and is cancelled if the timeout
+ is exceeded. Used on a method or assembly, sets the default timeout
+ for all contained test methods.
+
+
+
+
+ Construct a TimeoutAttribute given a time in milliseconds
+
+ The timeout value in milliseconds
+
+
+
+ Marks a test that must run in the STA, causing it
+ to run in a separate thread if necessary.
+
+ On methods, you may also use STAThreadAttribute
+ to serve the same purpose.
+
+
+
+
+ Construct a RequiresSTAAttribute
+
+
+
+
+ Marks a test that must run in the MTA, causing it
+ to run in a separate thread if necessary.
+
+ On methods, you may also use MTAThreadAttribute
+ to serve the same purpose.
+
+
+
+
+ Construct a RequiresMTAAttribute
+
+
+
+
+ Marks a test that must run on a separate thread.
+
+
+
+
+ Construct a RequiresThreadAttribute
+
+
+
+
+ Construct a RequiresThreadAttribute, specifying the apartment
+
+
+
+
+ ValueSourceAttribute indicates the source to be used to
+ provide data for one parameter of a test method.
+
+
+
+
+ Construct with the name of the factory - for use with languages
+ that don't support params arrays.
+
+ The name of the data source to be used
+
+
+
+ Construct with a Type and name - for use with languages
+ that don't support params arrays.
+
+ The Type that will provide data
+ The name of the method, property or field that will provide data
+
+
+
+ The name of a the method, property or fiend to be used as a source
+
+
+
+
+ A Type to be used as a source
+
+
+
+
+ AllItemsConstraint applies another constraint to each
+ item in a collection, succeeding if they all succeed.
+
+
+
+
+ Abstract base class used for prefixes
+
+
+
+
+ The Constraint class is the base of all built-in constraints
+ within NUnit. It provides the operator overloads used to combine
+ constraints.
+
+
+
+
+ The IConstraintExpression interface is implemented by all
+ complete and resolvable constraints and expressions.
+
+
+
+
+ Return the top-level constraint for this expression
+
+
+
+
+
+ Static UnsetObject used to detect derived constraints
+ failing to set the actual value.
+
+
+
+
+ The actual value being tested against a constraint
+
+
+
+
+ The display name of this Constraint for use by ToString()
+
+
+
+
+ Argument fields used by ToString();
+
+
+
+
+ The builder holding this constraint
+
+
+
+
+ Construct a constraint with no arguments
+
+
+
+
+ Construct a constraint with one argument
+
+
+
+
+ Construct a constraint with two arguments
+
+
+
+
+ Sets the ConstraintBuilder holding this constraint
+
+
+
+
+ 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
+
+
+
+ Test whether the constraint is satisfied by an
+ ActualValueDelegate that returns the value to be tested.
+ The default implementation simply evaluates the delegate
+ but derived classes may override it to provide for delayed
+ processing.
+
+ An
+ True for success, false for failure
+
+
+
+ Test whether the constraint is satisfied by a given reference.
+ The default implementation simply dereferences the value but
+ derived classes may override it to provide for delayed processing.
+
+ A reference to 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
+
+
+
+ Default override of ToString returns the constraint DisplayName
+ followed by any arguments within angle brackets.
+
+
+
+
+
+ Returns the string representation of this constraint
+
+
+
+
+ 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.
+
+
+
+
+ Returns a DelayedConstraint with the specified delay time.
+
+ The delay in milliseconds.
+
+
+
+
+ Returns a DelayedConstraint with the specified delay time
+ and polling interval.
+
+ The delay in milliseconds.
+ The interval at which to test the constraint.
+
+
+
+
+ The display name of this Constraint for use by ToString().
+ The default value is the name of the constraint with
+ trailing "Constraint" removed. Derived classes may set
+ this to another name in their constructors.
+
+
+
+
+ Returns a ConstraintExpression by appending And
+ to the current constraint.
+
+
+
+
+ Returns a ConstraintExpression by appending And
+ to the current constraint.
+
+
+
+
+ Returns a ConstraintExpression by appending Or
+ to the current constraint.
+
+
+
+
+ Class used to detect any derived constraints
+ that fail to set the actual value in their
+ Matches override.
+
+
+
+
+ The base constraint
+
+
+
+
+ Construct given a base constraint
+
+
+
+
+
+ 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
+
+
+
+
+
+ AndConstraint succeeds only if both members succeed.
+
+
+
+
+ BinaryConstraint 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 BinaryConstraint from two other constraints
+
+ The first constraint
+ The second constraint
+
+
+
+ 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
+
+
+
+ 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
+
+
+
+ AssignableFromConstraint is used to test that an object
+ can be assigned from a given Type.
+
+
+
+
+ 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
+
+
+
+ Construct an AssignableFromConstraint for the type provided
+
+
+
+
+
+ Test whether an object can be assigned from the specified type
+
+ The object to be tested
+ True if the object can be assigned a value of the expected Type, otherwise false.
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+ The MessageWriter to use
+
+
+
+ AssignableToConstraint is used to test that an object
+ can be assigned to a given Type.
+
+
+
+
+ Construct an AssignableToConstraint for the type provided
+
+
+
+
+
+ Test whether an object can be assigned to the specified type
+
+ The object to be tested
+ True if the object can be assigned a value of the expected Type, otherwise false.
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+ The MessageWriter to use
+
+
+
+ AttributeConstraint tests that a specified attribute is present
+ on a Type or other provider and that the value of the attribute
+ satisfies some other constraint.
+
+
+
+
+ Constructs an AttributeConstraint for a specified attriute
+ Type and base constraint.
+
+
+
+
+
+
+ Determines whether the Type or other provider has the
+ expected attribute and if its value matches the
+ additional constraint specified.
+
+
+
+
+ Writes a description of the attribute to the specified writer.
+
+
+
+
+ Writes the actual value supplied to the specified writer.
+
+
+
+
+ Returns a string representation of the constraint.
+
+
+
+
+ AttributeExistsConstraint tests for the presence of a
+ specified attribute on a Type.
+
+
+
+
+ Constructs an AttributeExistsConstraint for a specific attribute Type
+
+
+
+
+
+ Tests whether the object provides the expected attribute.
+
+ A Type, MethodInfo, or other ICustomAttributeProvider
+ True if the expected attribute is present, otherwise false
+
+
+
+ Writes the description of the constraint to the specified writer
+
+
+
+
+ BasicConstraint is the abstract base for constraints that
+ perform a simple comparison to a constant value.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected.
+ The description.
+
+
+
+ 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
+
+
+
+ BinarySerializableConstraint tests whether
+ an object is serializable in binary format.
+
+
+
+
+ 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
+
+
+
+ Returns the string representation
+
+
+
+
+ CollectionConstraint is the abstract base class for
+ constraints that operate on collections.
+
+
+
+
+ Construct an empty CollectionConstraint
+
+
+
+
+ Construct a CollectionConstraint
+
+
+
+
+
+ Determines whether the specified enumerable is empty.
+
+ The enumerable.
+
+ true if the specified enumerable is empty; otherwise, false.
+
+
+
+
+ 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
+
+
+
+
+
+
+ CollectionContainsConstraint is used to test whether a collection
+ contains an expected object as a member.
+
+
+
+
+ CollectionItemsEqualConstraint is the abstract base class for all
+ collection constraints that apply some notion of item equality
+ as a part of their operation.
+
+
+
+
+ Construct an empty CollectionConstraint
+
+
+
+
+ Construct a CollectionConstraint
+
+
+
+
+
+ Flag the constraint to use the supplied EqualityAdapter.
+ NOTE: For internal use only.
+
+ The EqualityAdapter to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied Comparison object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Compares two collection members for equality
+
+
+
+
+ Return a new CollectionTally for use in making tests
+
+ The collection to be included in the tally
+
+
+
+ Flag the constraint to ignore case and return self.
+
+
+
+
+ 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
+
+
+
+
+
+ CollectionOrderedConstraint is used to test whether a collection is ordered.
+
+
+
+
+ Construct a CollectionOrderedConstraint
+
+
+
+
+ Modifies the constraint to use an IComparer and returns self.
+
+
+
+
+ Modifies the constraint to use an IComparer<T> and returns self.
+
+
+
+
+ Modifies the constraint to use a Comparison<T> and returns self.
+
+
+
+
+ Modifies the constraint to test ordering by the value of
+ a specified property and returns self.
+
+
+
+
+ Test whether the collection is ordered
+
+
+
+
+
+
+ Write a description of the constraint to a MessageWriter
+
+
+
+
+
+ Returns the string representation of the constraint.
+
+
+
+
+
+ If used performs a reverse comparison
+
+
+
+
+ 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
+
+
+
+
+
+ CollectionTally counts (tallies) the number of
+ occurences of each object in one or more enumerations.
+
+
+
+
+ Construct a CollectionTally object from a comparer and a collection
+
+
+
+
+ Try to remove an object from the tally
+
+ The object to remove
+ True if successful, false if the object was not found
+
+
+
+ Try to remove a set of objects from the tally
+
+ The objects to remove
+ True if successful, false if any object was not found
+
+
+
+ The number of objects remaining in the tally
+
+
+
+
+ ComparisonAdapter class centralizes all comparisons of
+ values in NUnit, adapting to the use of any provided
+ IComparer, IComparer<T> or Comparison<T>
+
+
+
+
+ Returns a ComparisonAdapter that wraps an IComparer
+
+
+
+
+ Returns a ComparisonAdapter that wraps an IComparer<T>
+
+
+
+
+ Returns a ComparisonAdapter that wraps a Comparison<T>
+
+
+
+
+ Compares two objects
+
+
+
+
+ Gets the default ComparisonAdapter, which wraps an
+ NUnitComparer object.
+
+
+
+
+ Construct a ComparisonAdapter for an IComparer
+
+
+
+
+ Compares two objects
+
+
+
+
+
+
+
+ Construct a default ComparisonAdapter
+
+
+
+
+ ComparisonAdapter<T> extends ComparisonAdapter and
+ allows use of an IComparer<T> or Comparison<T>
+ to actually perform the comparison.
+
+
+
+
+ Construct a ComparisonAdapter for an IComparer<T>
+
+
+
+
+ Compare a Type T to an object
+
+
+
+
+ Construct a ComparisonAdapter for a Comparison<T>
+
+
+
+
+ Compare a Type T to an object
+
+
+
+
+ Abstract base class for constraints that compare values to
+ determine if one is greater than, equal to or less than
+ the other. This class supplies the Using modifiers.
+
+
+
+
+ ComparisonAdapter to be used in making the comparison
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ Modifies the constraint to use an IComparer and returns self
+
+
+
+
+ Modifies the constraint to use an IComparer<T> and returns self
+
+
+
+
+ Modifies the constraint to use a Comparison<T> and returns self
+
+
+
+
+ Delegate used to delay evaluation of the actual value
+ to be used in evaluating a constraint
+
+
+
+
+ ConstraintBuilder maintains the stacks that are used in
+ processing a ConstraintExpression. An OperatorStack
+ is used to hold operators that are waiting for their
+ operands to be reognized. a ConstraintStack holds
+ input constraints as well as the results of each
+ operator applied.
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ Appends the specified operator to the expression by first
+ reducing the operator stack and then pushing the new
+ operator on the stack.
+
+ The operator to push.
+
+
+
+ Appends the specified constraint to the expresson by pushing
+ it on the constraint stack.
+
+ The constraint to push.
+
+
+
+ Sets the top operator right context.
+
+ The right context.
+
+
+
+ Reduces the operator stack until the topmost item
+ precedence is greater than or equal to the target precedence.
+
+ The target precedence.
+
+
+
+ Resolves this instance, returning a Constraint. If the builder
+ is not currently in a resolvable state, an exception is thrown.
+
+ The resolved constraint
+
+
+
+ Gets a value indicating whether this instance is resolvable.
+
+
+ true if this instance is resolvable; otherwise, false.
+
+
+
+
+ OperatorStack is a type-safe stack for holding ConstraintOperators
+
+
+
+
+ Initializes a new instance of the class.
+
+ The builder.
+
+
+
+ Pushes the specified operator onto the stack.
+
+ The op.
+
+
+
+ Pops the topmost operator from the stack.
+
+
+
+
+
+ Gets a value indicating whether this is empty.
+
+ true if empty; otherwise, false.
+
+
+
+ Gets the topmost operator without modifying the stack.
+
+ The top.
+
+
+
+ ConstraintStack is a type-safe stack for holding Constraints
+
+
+
+
+ Initializes a new instance of the class.
+
+ The builder.
+
+
+
+ Pushes the specified constraint. As a side effect,
+ the constraint's builder field is set to the
+ ConstraintBuilder owning this stack.
+
+ The constraint.
+
+
+
+ Pops this topmost constrait from the stack.
+ As a side effect, the constraint's builder
+ field is set to null.
+
+
+
+
+
+ Gets a value indicating whether this is empty.
+
+ true if empty; otherwise, false.
+
+
+
+ Gets the topmost constraint without modifying the stack.
+
+ The topmost constraint
+
+
+
+ ConstraintExpression represents a compound constraint in the
+ process of being constructed from a series of syntactic elements.
+
+ Individual elements are appended to the expression as they are
+ reognized. Once an actual Constraint is appended, the expression
+ returns a resolvable Constraint.
+
+
+
+
+ ConstraintExpressionBase is the abstract base class for the
+ ConstraintExpression class, which represents a
+ compound constraint in the process of being constructed
+ from a series of syntactic elements.
+
+ NOTE: ConstraintExpressionBase is separate because the
+ ConstraintExpression class was generated in earlier
+ versions of NUnit. The two classes may be combined
+ in a future version.
+
+
+
+
+ The ConstraintBuilder holding the elements recognized so far
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ Initializes a new instance of the
+ class passing in a ConstraintBuilder, which may be pre-populated.
+
+ The builder.
+
+
+
+ Returns a string representation of the expression as it
+ currently stands. This should only be used for testing,
+ since it has the side-effect of resolving the expression.
+
+
+
+
+
+ Appends an operator to the expression and returns the
+ resulting expression itself.
+
+
+
+
+ Appends a self-resolving operator to the expression and
+ returns a new ResolvableConstraintExpression.
+
+
+
+
+ Appends a constraint to the expression and returns that
+ constraint, which is associated with the current state
+ of the expression being built.
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ Initializes a new instance of the
+ class passing in a ConstraintBuilder, which may be pre-populated.
+
+ The builder.
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding only if a specified number of them succeed.
+
+
+
+
+ Returns a new PropertyConstraintExpression, which will either
+ test for the existence of the named property on the object
+ being tested or apply any following constraint to that property.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns a new AttributeConstraint checking for the
+ presence of a particular attribute on an object.
+
+
+
+
+ Returns the constraint provided as an argument - used to allow custom
+ custom constraints to easily participate in the syntax.
+
+
+
+
+ Returns the constraint provided as an argument - used to allow custom
+ custom constraints to easily participate in the syntax.
+
+
+
+
+ Returns a constraint that tests two items for equality
+
+
+
+
+ Returns a constraint that tests that two references are the same object
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is greater than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the
+ actual value is less than or equal to the suppled argument
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual
+ value is of the exact type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is of the type supplied as an argument or a derived type.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is assignable from the type supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a collection containing the same elements as the
+ collection supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the actual value
+ is a subset of the collection supplied as an argument.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a new CollectionContainsConstraint checking for the
+ presence of a particular object in the collection.
+
+
+
+
+ Returns a new ContainsConstraint. This constraint
+ will, in turn, make use of the appropriate second-level
+ constraint, depending on the type of the actual argument.
+ This overload is only used if the item sought is a string,
+ since any other type implies that we are looking for a
+ collection member.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value contains the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value starts with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value ends with the substring supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the regular expression supplied as an argument.
+
+
+
+
+ Returns a constraint that succeeds if the actual
+ value matches the regular expression supplied as an argument.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same as an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same path or under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the path provided
+ is the same path or under an expected path after canonicalization.
+
+
+
+
+ Returns a constraint that tests whether the actual value falls
+ within a specified range.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression that negates any
+ following constraint.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them succeed.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if at least one of them succeeds.
+
+
+
+
+ Returns a ConstraintExpression, which will apply
+ the following constraint to all members of a collection,
+ succeeding if all of them fail.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Length property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Count property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the Message property of the object being tested.
+
+
+
+
+ Returns a new ConstraintExpression, which will apply the following
+ constraint to the InnerException property of the object being tested.
+
+
+
+
+ With is currently a NOP - reserved for future use.
+
+
+
+
+ Returns a constraint that tests for null
+
+
+
+
+ Returns a constraint that tests for True
+
+
+
+
+ Returns a constraint that tests for False
+
+
+
+
+ Returns a constraint that tests for a positive value
+
+
+
+
+ Returns a constraint that tests for a negative value
+
+
+
+
+ Returns a constraint that tests for NaN
+
+
+
+
+ Returns a constraint that tests for empty
+
+
+
+
+ Returns a constraint that tests whether a collection
+ contains all unique items.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in binary format.
+
+
+
+
+ Returns a constraint that tests whether an object graph is serializable in xml format.
+
+
+
+
+ Returns a constraint that tests whether a collection is ordered
+
+
+
+
+ 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
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied Comparison object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to ignore case and return self.
+
+
+
+
+ Applies a delay to the match so that a match can be evaluated in the future.
+
+
+
+
+ Creates a new DelayedConstraint
+
+ The inner constraint two decorate
+ The time interval after which the match is performed
+ If the value of is less than 0
+
+
+
+ Creates a new DelayedConstraint
+
+ The inner constraint two decorate
+ The time interval after which the match is performed
+ The time interval used for polling
+ If the value of is less than 0
+
+
+
+ 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
+
+
+
+ Test whether the constraint is satisfied by a delegate
+
+ The delegate whose value is to be tested
+ True for if the base constraint fails, false if it succeeds
+
+
+
+ Test whether the constraint is satisfied by a given reference.
+ Overridden to wait for the specified delay period before
+ calling the base constraint with the dereferenced value.
+
+ A reference to 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 writer on which the actual value is displayed
+
+
+
+ Returns the string representation of the constraint.
+
+
+
+
+ EmptyCollectionConstraint tests whether a collection is empty.
+
+
+
+
+ Check that the collection is empty
+
+
+
+
+
+
+ Write the constraint description to a MessageWriter
+
+
+
+
+
+ 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.
+
+
+
+
+ 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
+
+
+
+ EmptyDirectoryConstraint is used to test that a directory is empty
+
+
+
+
+ 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
+
+
+
+ EmptyStringConstraint tests whether a string is empty.
+
+
+
+
+ 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
+
+
+
+ EndsWithConstraint can test whether a string ends
+ with an expected substring.
+
+
+
+
+ StringConstraint is the abstract base for constraints
+ that operate on strings. It supports the IgnoreCase
+ modifier for string operations.
+
+
+
+
+ The expected value
+
+
+
+
+ Indicates whether tests should be case-insensitive
+
+
+
+
+ Constructs a StringConstraint given an expected value
+
+ The expected value
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Test whether the constraint is satisfied by a given string
+
+ The string to be tested
+ True for success, false for failure
+
+
+
+ Modify the constraint to ignore case in matching.
+
+
+
+
+ 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
+
+
+
+ EqualConstraint is able to compare an actual value with the
+ expected value provided in its constructor. Two objects are
+ considered equal if both are null, or if both have the same
+ value. NUnit has special semantics for some object types.
+
+
+
+
+ If true, strings in error messages will be clipped
+
+
+
+
+ NUnitEqualityComparer used to test equality.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ Flag the constraint to use a tolerance when determining equality.
+
+ Tolerance value to be used
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied Comparison object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ Flag the constraint to use the supplied IEqualityComparer object.
+
+ The IComparer object to use.
+ Self.
+
+
+
+ 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
+
+
+
+ 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 enumerations, 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
+
+
+
+ Display the failure information for two IEnumerables that did not match.
+
+ The MessageWriter on which to display
+ The expected enumeration.
+ The actual enumeration
+ The depth of this failure in a set of nested collections
+
+
+
+ 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.
+
+
+
+
+ Switches the .Within() modifier to interpret its tolerance as
+ a distance in representable values (see remarks).
+
+ Self.
+
+ Ulp stands for "unit in the last place" and describes the minimum
+ amount a given value can change. For any integers, an ulp is 1 whole
+ digit. For floating point values, the accuracy of which is better
+ for smaller numbers and worse for larger numbers, an ulp depends
+ on the size of the number. Using ulps for comparison of floating
+ point results instead of fixed tolerances is safer because it will
+ automatically compensate for the added inaccuracy of larger numbers.
+
+
+
+
+ Switches the .Within() modifier to interpret its tolerance as
+ a percentage that the actual values is allowed to deviate from
+ the expected value.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in days.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in hours.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in minutes.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in seconds.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in milliseconds.
+
+ Self
+
+
+
+ Causes the tolerance to be interpreted as a TimeSpan in clock ticks.
+
+ Self
+
+
+
+ EqualityAdapter class handles all equality comparisons
+ that use an IEqualityComparer, IEqualityComparer<T>
+ or a ComparisonAdapter.
+
+
+
+
+ Compares two objects, returning true if they are equal
+
+
+
+
+ Returns true if the two objects can be compared by this adapter.
+ The base adapter cannot handle IEnumerables except for strings.
+
+
+
+
+ Returns an EqualityAdapter that wraps an IComparer.
+
+
+
+
+ Returns an EqualityAdapter that wraps an IEqualityComparer.
+
+
+
+
+ Returns an EqualityAdapter that wraps an IEqualityComparer<T>.
+
+
+
+
+ Returns an EqualityAdapter that wraps an IComparer<T>.
+
+
+
+
+ Returns an EqualityAdapter that wraps a Comparison<T>.
+
+
+
+
+ EqualityAdapter that wraps an IComparer.
+
+
+
+
+ Returns true if the two objects can be compared by this adapter.
+ Generic adapter requires objects of the specified type.
+
+
+
+
+ EqualityAdapter that wraps an IComparer.
+
+
+
+
+ EqualityAdapterList represents a list of EqualityAdapters
+ in a common class across platforms.
+
+
+
+
+ ExactCountConstraint applies another constraint to each
+ item in a collection, succeeding only if a specified
+ number of items succeed.
+
+
+
+
+ Construct an ExactCountConstraint on top of an existing constraint
+
+
+
+
+
+
+ Apply the item constraint to each item in the collection,
+ succeeding only if the expected number of items pass.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ ExactTypeConstraint is used to test that an object
+ is of the exact type provided in the constructor
+
+
+
+
+ Construct an ExactTypeConstraint for a given Type
+
+ The expected Type.
+
+
+
+ Test that an object is of the exact type specified
+
+ The actual value.
+ True if the tested object is of the exact type provided, otherwise false.
+
+
+
+ Write the description of this constraint to a MessageWriter
+
+ The MessageWriter to use
+
+
+
+ ExceptionTypeConstraint is a special version of ExactTypeConstraint
+ used to provided detailed info about the exception thrown in
+ an error message.
+
+
+
+
+ Constructs an ExceptionTypeConstraint
+
+
+
+
+ Write the actual value for a failing constraint test to a
+ MessageWriter. Overriden to write additional information
+ in the case of an Exception.
+
+ The MessageWriter to use
+
+
+
+ FailurePoint class represents one point of failure
+ in an equality test.
+
+
+
+
+ The location of the failure
+
+
+
+
+ The expected value
+
+
+
+
+ The actual value
+
+
+
+
+ Indicates whether the expected value is valid
+
+
+
+
+ Indicates whether the actual value is valid
+
+
+
+
+ FailurePointList represents a set of FailurePoints
+ in a cross-platform way.
+
+
+
+
+ FalseConstraint tests that the actual value is false
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+ Helper routines for working with floating point numbers
+
+
+ The floating point comparison code is based on this excellent article:
+ http://www.cygnus-software.com/papers/comparingfloats/comparingfloats.htm
+
+
+ "ULP" means Unit in the Last Place and in the context of this library refers to
+ the distance between two adjacent floating point numbers. IEEE floating point
+ numbers can only represent a finite subset of natural numbers, with greater
+ accuracy for smaller numbers and lower accuracy for very large numbers.
+
+
+ If a comparison is allowed "2 ulps" of deviation, that means the values are
+ allowed to deviate by up to 2 adjacent floating point values, which might be
+ as low as 0.0000001 for small numbers or as high as 10.0 for large numbers.
+
+
+
+
+ Compares two floating point values for equality
+ First floating point value to be compared
+ Second floating point value t be compared
+
+ Maximum number of representable floating point values that are allowed to
+ be between the left and the right floating point values
+
+ True if both numbers are equal or close to being equal
+
+
+ Floating point values can only represent a finite subset of natural numbers.
+ For example, the values 2.00000000 and 2.00000024 can be stored in a float,
+ but nothing inbetween them.
+
+
+ This comparison will count how many possible floating point values are between
+ the left and the right number. If the number of possible values between both
+ numbers is less than or equal to maxUlps, then the numbers are considered as
+ being equal.
+
+
+ Implementation partially follows the code outlined here:
+ http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/
+
+
+
+
+ Compares two double precision floating point values for equality
+ First double precision floating point value to be compared
+ Second double precision floating point value t be compared
+
+ Maximum number of representable double precision floating point values that are
+ allowed to be between the left and the right double precision floating point values
+
+ True if both numbers are equal or close to being equal
+
+
+ Double precision floating point values can only represent a limited series of
+ natural numbers. For example, the values 2.0000000000000000 and 2.0000000000000004
+ can be stored in a double, but nothing inbetween them.
+
+
+ This comparison will count how many possible double precision floating point
+ values are between the left and the right number. If the number of possible
+ values between both numbers is less than or equal to maxUlps, then the numbers
+ are considered as being equal.
+
+
+ Implementation partially follows the code outlined here:
+ http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/
+
+
+
+
+
+ Reinterprets the memory contents of a floating point value as an integer value
+
+
+ Floating point value whose memory contents to reinterpret
+
+
+ The memory contents of the floating point value interpreted as an integer
+
+
+
+
+ Reinterprets the memory contents of a double precision floating point
+ value as an integer value
+
+
+ Double precision floating point value whose memory contents to reinterpret
+
+
+ The memory contents of the double precision floating point value
+ interpreted as an integer
+
+
+
+
+ Reinterprets the memory contents of an integer as a floating point value
+
+ Integer value whose memory contents to reinterpret
+
+ The memory contents of the integer value interpreted as a floating point value
+
+
+
+
+ Reinterprets the memory contents of an integer value as a double precision
+ floating point value
+
+ Integer whose memory contents to reinterpret
+
+ The memory contents of the integer interpreted as a double precision
+ floating point value
+
+
+
+ Union of a floating point variable and an integer
+
+
+ The union's value as a floating point variable
+
+
+ The union's value as an integer
+
+
+ The union's value as an unsigned integer
+
+
+ Union of a double precision floating point variable and a long
+
+
+ The union's value as a double precision floating point variable
+
+
+ The union's value as a long
+
+
+ The union's value as an unsigned long
+
+
+
+ Tests whether a value is greater than the value supplied to its constructor
+
+
+
+
+ The value against which a comparison is to be made
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ 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
+
+
+
+ Tests whether a value is greater than or equal to the value supplied to its constructor
+
+
+
+
+ The value against which a comparison is to be made
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ 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
+
+
+
+ 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
+
+ The expected Type
+
+
+
+ Test whether an object is of the specified type or a derived type
+
+ The object to be tested
+ True if the object is of the provided type or derives from it, otherwise false.
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+ The MessageWriter to use
+
+
+
+ Tests whether a value is less than the value supplied to its constructor
+
+
+
+
+ The value against which a comparison is to be made
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ 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
+
+
+
+ Tests whether a value is less than or equal to the value supplied to its constructor
+
+
+
+
+ The value against which a comparison is to be made
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected value.
+
+
+
+ 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
+
+
+
+ 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 enumerable,
+ 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
+
+
+
+ NaNConstraint tests that the actual value is a double or float NaN
+
+
+
+
+ Test that the actual value is an NaN
+
+
+
+
+
+
+ Write the constraint description to a specified writer
+
+
+
+
+
+ NoItemConstraint applies another constraint to each
+ item in a collection, failing if any of them succeeds.
+
+
+
+
+ Construct a NoItemConstraint 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
+
+
+
+
+
+ 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
+
+
+
+ NullConstraint tests that the actual value is null
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ NullEmptyStringConstraint tests whether a string is either null or empty.
+
+
+
+
+ Constructs a new NullOrEmptyStringConstraint
+
+
+
+
+ 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
+
+
+
+ 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 tolerance
+ provided is Empty, this method may set it to a default tolerance.
+
+ The expected value
+ The actual value
+ A reference to the tolerance in effect
+ True if the values are equal
+
+
+
+ Compare two numeric values, performing the usual numeric conversions.
+
+ The expected value
+ The actual value
+ The relationship of the values to each other
+
+
+
+ NUnitComparer encapsulates NUnit's default behavior
+ in comparing two objects.
+
+
+
+
+ Compares two objects
+
+
+
+
+
+
+
+ Returns the default NUnitComparer.
+
+
+
+
+ Generic version of NUnitComparer
+
+
+
+
+
+ Compare two objects of the same type
+
+
+
+
+ NUnitEqualityComparer encapsulates NUnit's handling of
+ equality tests between objects.
+
+
+
+
+
+
+
+
+
+ Compares two objects for equality within a tolerance
+
+ The first object to compare
+ The second object to compare
+ The tolerance to use in the comparison
+
+
+
+
+ If true, all string comparisons will ignore case
+
+
+
+
+ If true, arrays will be treated as collections, allowing
+ those of different dimensions to be compared
+
+
+
+
+ Comparison objects used in comparisons for some constraints.
+
+
+
+
+ List of points at which a failure occured.
+
+
+
+
+ RecursionDetector used to check for recursion when
+ evaluating self-referencing enumerables.
+
+
+
+
+ Compares two objects for equality within a tolerance, setting
+ the tolerance to the actual tolerance used if an empty
+ tolerance is supplied.
+
+
+
+
+ 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
+
+
+
+ Returns the default NUnitEqualityComparer
+
+
+
+
+ Gets and sets a flag indicating whether case should
+ be ignored in determining equality.
+
+
+
+
+ Gets and sets a flag indicating that arrays should be
+ compared as collections, without regard to their shape.
+
+
+
+
+ Gets the list of external comparers to be used to
+ test for equality. They are applied to members of
+ collections, in place of NUnit's own logic.
+
+
+
+
+ Gets the list of failure points for the last Match performed.
+ The list consists of objects to be interpreted by the caller.
+ This generally means that the caller may only make use of
+ objects it has placed on the list at a particular depthy.
+
+
+
+
+ RecursionDetector detects when a comparison
+ between two enumerables has reached a point
+ where the same objects that were previously
+ compared are again being compared. This allows
+ the caller to stop the comparison if desired.
+
+
+
+
+ Check whether two objects have previously
+ been compared, returning true if they have.
+ The two objects are remembered, so that a
+ second call will always return true.
+
+
+
+
+ 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
+
+
+
+ PathConstraint serves as the abstract base of constraints
+ that operate on paths and provides several helper methods.
+
+
+
+
+ The expected path used in the constraint
+
+
+
+
+ Flag indicating whether a caseInsensitive comparison should be made
+
+
+
+
+ Construct a PathConstraint for a give expected path
+
+ The expected path
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True for success, false for failure
+
+
+
+ Returns true if the expected path and actual path match
+
+
+
+
+ Returns the string representation of this constraint
+
+
+
+
+ Transform the provided path to its canonical form so that it
+ may be more easily be compared with other paths.
+
+ The original path
+ The path in canonical form
+
+
+
+ Test whether one path in canonical form is under another.
+
+ The first path - supposed to be the parent path
+ The second path - supposed to be the child path
+ Indicates whether case should be ignored
+
+
+
+
+ Modifies the current instance to be case-insensitve
+ and returns it.
+
+
+
+
+ Modifies the current instance to be case-sensitve
+ and returns it.
+
+
+
+
+ Predicate constraint wraps a Predicate in a constraint,
+ returning success if the predicate is true.
+
+
+
+
+ Construct a PredicateConstraint from a predicate
+
+
+
+
+ Determines whether the predicate succeeds when applied
+ to the actual value.
+
+
+
+
+ Writes the description to a MessageWriter
+
+
+
+
+ PropertyConstraint extracts a named property and uses
+ its value as the actual value for a chained constraint.
+
+
+
+
+ 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
+
+
+
+ Returns the string representation of the constraint.
+
+
+
+
+
+ PropertyExistsConstraint tests that a named property
+ exists on the object provided through Match.
+
+ Originally, PropertyConstraint provided this feature
+ in addition to making optional tests on the vaue
+ of the property. The two constraints are now separate.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The name of the property.
+
+
+
+ Test whether the property exists for a given object
+
+ The object 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 writer on which the actual value is displayed
+
+
+
+ Returns the string representation of the constraint.
+
+
+
+
+
+ RangeConstraint tests whether two values are within a
+ specified range.
+
+
+
+
+ Initializes a new instance of the class.
+
+ From.
+ To.
+
+
+
+ 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
+
+
+
+ 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
+
+
+
+ ResolvableConstraintExpression is used to represent a compound
+ constraint being constructed at a point where the last operator
+ may either terminate the expression or may have additional
+ qualifying constraints added to it.
+
+ It is used, for example, for a Property element or for
+ an Exception element, either of which may be optionally
+ followed by constraints that apply to the property or
+ exception.
+
+
+
+
+ Create a new instance of ResolvableConstraintExpression
+
+
+
+
+ Create a new instance of ResolvableConstraintExpression,
+ passing in a pre-populated ConstraintBuilder.
+
+
+
+
+ Resolve the current expression to a Constraint
+
+
+
+
+ This operator creates a constraint that is satisfied only if both
+ argument constraints are satisfied.
+
+
+
+
+ This operator creates a constraint that is satisfied only if both
+ argument constraints are satisfied.
+
+
+
+
+ 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 either
+ of the argument constraints is 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.
+
+
+
+
+ Appends an And Operator to the expression
+
+
+
+
+ Appends an Or operator to the expression.
+
+
+
+
+ ReusableConstraint wraps a constraint expression after
+ resolving it so that it can be reused consistently.
+
+
+
+
+ Construct a ReusableConstraint from a constraint expression
+
+ The expression to be resolved and reused
+
+
+
+ Converts a constraint to a ReusableConstraint
+
+ The constraint to be converted
+ A ReusableConstraint
+
+
+
+ Returns the string representation of the constraint.
+
+ A string representing the constraint
+
+
+
+ Resolves the ReusableConstraint by returning the constraint
+ that it originally wrapped.
+
+ A resolved constraint
+
+
+
+ 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
+
+
+
+ Summary description for SamePathConstraint.
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected path
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The expected path
+ The actual path
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ SamePathOrUnderConstraint tests that one path is under another
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected path
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The expected path
+ The actual path
+ True for success, false for failure
+
+
+
+ Write the constraint description to a MessageWriter
+
+ The writer on which the description is displayed
+
+
+
+ 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,
+ succeeding if any item succeeds.
+
+
+
+
+
+
+ Write a description of this constraint to a MessageWriter
+
+
+
+
+
+ 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
+
+
+
+ SubPathConstraint tests that the actual path is under the expected path
+
+
+
+
+ Initializes a new instance of the class.
+
+ The expected path
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The expected path
+ The actual path
+ 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
+
+
+
+ ThrowsConstraint is used to test the exception thrown by
+ a delegate by applying a constraint to it.
+
+
+
+
+ Initializes a new instance of the class,
+ using a constraint to be applied to the exception.
+
+ A constraint to apply to the caught exception.
+
+
+
+ Executes the code of the delegate and captures any exception.
+ If a non-null base constraint was provided, it applies that
+ constraint to the exception.
+
+ A delegate representing the code to be tested
+ True if an exception is thrown and the constraint succeeds, otherwise false
+
+
+
+ Converts an ActualValueDelegate to a TestDelegate
+ before calling the primary overload.
+
+
+
+
+ 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
+
+
+
+ Returns the string representation of this constraint
+
+
+
+
+ Get the actual exception thrown - used by Assert.Throws.
+
+
+
+
+ ThrowsNothingConstraint tests that a delegate does not
+ throw an exception.
+
+
+
+
+ Test whether the constraint is satisfied by a given value
+
+ The value to be tested
+ True if no exception is thrown, otherwise false
+
+
+
+ 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. Overridden in ThrowsNothingConstraint to write
+ information about the exception that was actually caught.
+
+ The writer on which the actual value is displayed
+
+
+
+ The Tolerance class generalizes the notion of a tolerance
+ within which an equality test succeeds. Normally, it is
+ used with numeric types, but it can be used with any
+ type that supports taking a difference between two
+ objects and comparing that difference to a value.
+
+
+
+
+ Constructs a linear tolerance of a specdified amount
+
+
+
+
+ Constructs a tolerance given an amount and ToleranceMode
+
+
+
+
+ Tests that the current Tolerance is linear with a
+ numeric value, throwing an exception if it is not.
+
+
+
+
+ Returns an empty Tolerance object, equivalent to
+ specifying no tolerance. In most cases, it results
+ in an exact match but for floats and doubles a
+ default tolerance may be used.
+
+
+
+
+ Returns a zero Tolerance object, equivalent to
+ specifying an exact match.
+
+
+
+
+ Gets the ToleranceMode for the current Tolerance
+
+
+
+
+ Gets the value of the current Tolerance instance.
+
+
+
+
+ Returns a new tolerance, using the current amount as a percentage.
+
+
+
+
+ Returns a new tolerance, using the current amount in Ulps.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of days.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of hours.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of minutes.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of seconds.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of milliseconds.
+
+
+
+
+ Returns a new tolerance with a TimeSpan as the amount, using
+ the current amount as a number of clock ticks.
+
+
+
+
+ Returns true if the current tolerance is empty.
+
+
+
+
+ Modes in which the tolerance value for a comparison can be interpreted.
+
+
+
+
+ The tolerance was created with a value, without specifying
+ how the value would be used. This is used to prevent setting
+ the mode more than once and is generally changed to Linear
+ upon execution of the test.
+
+
+
+
+ The tolerance is used as a numeric range within which
+ two compared values are considered to be equal.
+
+
+
+
+ Interprets the tolerance as the percentage by which
+ the two compared values my deviate from each other.
+
+
+
+
+ Compares two values based in their distance in
+ representable numbers.
+
+
+
+
+ TrueConstraint tests that the actual value is true
+
+
+
+
+ Initializes a new instance of the class.
+
+
+
+
+ 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
+
+
+
+
+
+ XmlSerializableConstraint tests whether
+ an object is serializable in XML format.
+
+
+
+
+ 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
+
+
+
+ Returns the string representation of this constraint
+
+
+
+
+ Represents a constraint that succeeds if all the
+ members of a collection match a base constraint.
+
+
+
+
+ Abstract base for operators that indicate how to
+ apply a constraint to items in a collection.
+
+
+
+
+ PrefixOperator takes a single constraint and modifies
+ it's action in some way.
+
+
+
+
+ The ConstraintOperator class is used internally by a
+ ConstraintBuilder to represent an operator that
+ modifies or combines constraints.
+
+ Constraint operators use left and right precedence
+ values to determine whether the top operator on the
+ stack should be reduced before pushing a new operator.
+
+
+
+
+ The precedence value used when the operator
+ is about to be pushed to the stack.
+
+
+
+
+ The precedence value used when the operator
+ is on the top of the stack.
+
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+
+ The syntax element preceding this operator
+
+
+
+
+ The syntax element folowing this operator
+
+
+
+
+ The precedence value used when the operator
+ is about to be pushed to the stack.
+
+
+
+
+ The precedence value used when the operator
+ is on the top of the stack.
+
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+
+ Returns the constraint created by applying this
+ prefix to another constraint.
+
+
+
+
+
+
+ Constructs a CollectionOperator
+
+
+
+
+ Returns a constraint that will apply the argument
+ to the members of a collection, succeeding if
+ they all succeed.
+
+
+
+
+ Operator that requires both it's arguments to succeed
+
+
+
+
+ Abstract base class for all binary operators
+
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+
+ Abstract method that produces a constraint by applying
+ the operator to its left and right constraint arguments.
+
+
+
+
+ Gets the left precedence of the operator
+
+
+
+
+ Gets the right precedence of the operator
+
+
+
+
+ Construct an AndOperator
+
+
+
+
+ Apply the operator to produce an AndConstraint
+
+
+
+
+ Operator that tests for the presence of a particular attribute
+ on a type and optionally applies further tests to the attribute.
+
+
+
+
+ Abstract base class for operators that are able to reduce to a
+ constraint whether or not another syntactic element follows.
+
+
+
+
+ Construct an AttributeOperator for a particular Type
+
+ The Type of attribute tested
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+ Represents a constraint that succeeds if the specified
+ count of members of a collection match a base constraint.
+
+
+
+
+ Construct an ExactCountOperator for a specified count
+
+ The expected count
+
+
+
+ Returns a constraint that will apply the argument
+ to the members of a collection, succeeding if
+ none of them succeed.
+
+
+
+
+ Represents a constraint that succeeds if none of the
+ members of a collection match a base constraint.
+
+
+
+
+ Returns a constraint that will apply the argument
+ to the members of a collection, succeeding if
+ none of them succeed.
+
+
+
+
+ Negates the test of the constraint it wraps.
+
+
+
+
+ Constructs a new NotOperator
+
+
+
+
+ Returns a NotConstraint applied to its argument.
+
+
+
+
+ Operator that requires at least one of it's arguments to succeed
+
+
+
+
+ Construct an OrOperator
+
+
+
+
+ Apply the operator to produce an OrConstraint
+
+
+
+
+ Operator used to test for the presence of a named Property
+ on an object and optionally apply further tests to the
+ value of that property.
+
+
+
+
+ Constructs a PropOperator for a particular named property
+
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+
+ Gets the name of the property to which the operator applies
+
+
+
+
+ Represents a constraint that succeeds if any of the
+ members of a collection match a base constraint.
+
+
+
+
+ Returns a constraint that will apply the argument
+ to the members of a collection, succeeding if
+ any of them succeed.
+
+
+
+
+ Operator that tests that an exception is thrown and
+ optionally applies further tests to the exception.
+
+
+
+
+ Construct a ThrowsOperator
+
+
+
+
+ Reduce produces a constraint from the operator and
+ any arguments. It takes the arguments from the constraint
+ stack and pushes the resulting constraint on it.
+
+
+
+
+ Represents a constraint that simply wraps the
+ constraint provided as an argument, without any
+ further functionality, but which modifes the
+ order of evaluation because of its precedence.
+
+
+
+
+ Constructor for the WithOperator
+
+
+
+
+ Returns a constraint that wraps its argument
+
+
+
+
+ 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
+
+
+
+
+ Thrown when an assertion failed.
+
+
+
+
+
+
+ The error message that explains
+ the reason for the exception
+ The exception that caused the
+ current exception
+
+
+
+ Serialization Constructor
+
+
+
+
+ Thrown when a test executes inconclusively.
+
+
+
+ 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
+
+
+
+
+ Thrown when an assertion failed.
+
+
+
+
+
+
+ The error message that explains
+ the reason for the exception
+ The exception that caused the
+ current exception
+
+
+
+ Serialization Constructor
+
+
+
+
+
+
+
+
+
+
+ Compares two objects of a given Type for equality within a tolerance
+
+ The first object to compare
+ The second object to compare
+ The tolerance to use in the comparison
+
+
+
+
diff --git a/packages/NUnit.2.6.3/license.txt b/packages/NUnit.2.6.3/license.txt
new file mode 100644
index 0000000..b12903a
--- /dev/null
+++ b/packages/NUnit.2.6.3/license.txt
@@ -0,0 +1,15 @@
+Copyright © 2002-2013 Charlie Poole
+Copyright © 2002-2004 James W. Newkirk, Michael C. Two, Alexei A. Vorontsov
+Copyright © 2000-2002 Philip A. Craig
+
+This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.
+
+Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:
+
+1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment (see the following) in the product documentation is required.
+
+Portions Copyright © 2002-2013 Charlie Poole or Copyright © 2002-2004 James W. Newkirk, Michael C. Two, Alexei A. Vorontsov or Copyright © 2000-2002 Philip A. Craig
+
+2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
+
+3. This notice may not be removed or altered from any source distribution.
diff --git a/packages/repositories.config b/packages/repositories.config
new file mode 100644
index 0000000..10a110f
--- /dev/null
+++ b/packages/repositories.config
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file