This list is closed, nobody may subscribe to it.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(13) |
Oct
(49) |
Nov
(1) |
Dec
(8) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(12) |
Feb
(42) |
Mar
(61) |
Apr
(36) |
May
(20) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(7) |
2004 |
Jan
(29) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(5) |
2005 |
Jan
(12) |
Feb
(5) |
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(15) |
Nov
(89) |
Dec
(85) |
2006 |
Jan
(17) |
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <gc...@us...> - 2003-04-07 00:44:01
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Xml/XPath In directory sc8-pr-cvs1:/tmp/cvs-serv23859/DotNetMock.Framework/Xml/XPath Added Files: MockXPathDocument.cs MockXPathNavigator.cs MockXPathNodeIterator.cs Log Message: Added Mock Objects for System.Xml.XPath namespace: XPathDocument, XPathNavigator, XPathNodeIterator Added MockObject & NUnitTest wizards Added nunit.framework.dll to distribution Fixed Master build install of VisualStudioTemplates Added various comments and XML documentation to various classes --- NEW FILE: MockXPathDocument.cs --- /* * ============================================================================ * The Apache Software License, Version 1.1 * ============================================================================ * * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without modifica- * tion, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * 2. 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. * * 3. The end-user documentation included with the redistribution, if any, must * include the following acknowledgment: "This product includes software * developed by the Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowledgment may appear in the software itself, if * and wherever such third-party acknowledgments normally appear. * * 4. The names "log4j" and "Apache Software Foundation" must not be used to * endorse or promote products derived from this software without prior * written permission. For written permission, please contact * ap...@ap.... * * 5. Products derived from this software may not be called "Apache", nor may * "Apache" appear in their name, without prior written permission of the * Apache Software Foundation. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- * DING, 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. * * This software consists of voluntary contributions made by many individuals * on behalf of the Apache Software Foundation. For more information on the * Apache Software Foundation, please see <http://www.apache.org/>. * */ using System; using System.Xml; using System.Xml.XPath; using DotNetMock; namespace DotNetMock.Framework.Xml.XPath { /// <summary> /// Mock Object implementing extending the XPathDocument class /// </summary> public class MockXPathDocument : XPathDocument, IMockObject { private string name = ""; /// <summary> /// Number of CreateNavigator() calls to expect /// </summary> private ExpectationCounter _createNavigatorCalls = new ExpectationCounter("MockXPathNavigable.CreateNavigatorCount"); /// <summary> /// Exception to throw on CreateNavigator() call /// </summary> private Exception _expectedException = null; /// <summary> /// XPathNavigator to be returned by a CreateNavigator() call /// </summary> private XPathNavigator _expectedNavigator = null; /// <summary> /// Default Constructor. /// </summary> public MockXPathDocument( ) : base("../DotNetMock.Master.build") { this.name = "MockXPathDocument"; } #region Mock Methods /// <summary> /// Sets exception to throw on CreateNavigator() calls /// </summary> /// <param name="expected">Excepiton to throw</param> public void SetExpectedCreateException( Exception expected ) { _expectedException = expected; } /// <summary> /// Sets number of CreateNavigator() calls to expect /// </summary> /// <param name="count">Calls to expect</param> public void SetExpectedCreateCalls( int count ) { _createNavigatorCalls.Expected = count; } /// <summary> /// Sets instance of an XPathNavigator subclass to return on CreateNavigator() calls /// </summary> /// <param name="navigator">XPathNavigator subclass to return</param> public void SetExpectedNavigator( XPathNavigator navigator ) { _expectedNavigator = navigator; } #endregion #region Implementation of IXPathNavigable /// <summary> /// 1) Increments the number of CreateNavigator() calls /// 2) If there is an exception to throw, it is thrown /// 3) If there is an expected XPathNavigator to return, it is returned /// 4) Otherwise, a default empty <seealso cref="MockXPathNavigator">MockXPathNavigator</seealso> is returned /// </summary> /// <returns></returns> public new System.Xml.XPath.XPathNavigator CreateNavigator() { _createNavigatorCalls.Inc(); if ( _expectedException != null ) { throw _expectedException; } if ( _expectedNavigator != null ) { return _expectedNavigator; } else { return (XPathNavigator) new MockXPathNavigator(); } } #endregion #region Implementation of IMockObject public void NotImplemented(string methodName) { throw new NotImplementedException(methodName + " is currently not implemented."); } public string MockName { get { return name; } set { name = value; } } #endregion #region Implementation of IVerifiable public void Verify() { Verifier.Verify( this ); } #endregion } } --- NEW FILE: MockXPathNavigator.cs --- using System; using System.Xml.XPath; using DotNetMock; namespace DotNetMock.Framework.Xml.XPath { public class MockXPathNavigator : XPathNavigator, IMockObject { /// <summary> /// Mock Object name /// </summary> private string name = ""; /// <summary> /// Expected number of Select*() calls /// </summary> private ExpectationCounter _selectCalls = new ExpectationCounter("MockXPathNavigator.SelectCalls"); /// <summary> /// Expected Exception to be thrown for Select*() calls /// </summary> private Exception _expectedException = null; /// <summary> /// Expected MockXPathNodeIterator to return /// </summary> private MockXPathNodeIterator _iterator = new MockXPathNodeIterator(); public MockXPathNavigator() { this.name = "MockXPathNavigator"; } #region Mock Methods public void SetExpectedIterator( MockXPathNodeIterator iterator ) { _iterator = iterator; } public void SetExpectedSelectCalls( int selectCalls ) { _selectCalls.Expected = selectCalls; } public void SetExpectedException( Exception exception ) { _expectedException = exception; } #endregion #region Overrides of XPathNavigator public override string BaseURI { get { NotImplemented("MockXPathNavigator.BaseURI"); return null; } } public override System.Xml.XPath.XPathNavigator Clone() { NotImplemented("MockXPathNavigator.Clone"); return null; } public override string GetAttribute(string localName, string namespaceURI) { NotImplemented("MockXPathNavigator.GetAttribute"); return null; } public override string GetNamespace(string name) { NotImplemented("MockXPathNavigator.GetNamespace"); return null; } public override bool HasAttributes { get { NotImplemented("MockXPathNavigator.HasAttributes"); return false; } } public override bool HasChildren { get { NotImplemented("MockXPathNavigator.HasChildren"); return false; } } public override bool IsEmptyElement { get { NotImplemented("MockXPathNavigator.IsEmptyElement"); return false; } } public override bool IsSamePosition(System.Xml.XPath.XPathNavigator other) { NotImplemented("MockXPathNavigator.IsSamePosition"); return false; } public override string LocalName { get { NotImplemented("MockXPathNavigator.LocalName"); return null; } } public override bool MoveTo(System.Xml.XPath.XPathNavigator other) { NotImplemented("MockXPathNavigator.MoveTo"); return false; } public override bool MoveToAttribute(string localName, string namespaceURI) { NotImplemented("MockXPathNavigator.MoveToAttribute"); return false; } public override bool MoveToFirst() { NotImplemented("MockXPathNavigator.MoveToFirst"); return false; } public override bool MoveToFirstAttribute() { NotImplemented("MockXPathNavigator.MoveToFirstAttribute"); return false; } public override bool MoveToFirstChild() { NotImplemented("MockXPathNavigator.MoveToFirstChild"); return false; } public override bool MoveToFirstNamespace(System.Xml.XPath.XPathNamespaceScope namespaceScope) { NotImplemented("MockXPathNavigator.MoveToFirstNamespace"); return false; } public override bool MoveToId(string id) { NotImplemented("MockXPathNavigator.MoveToId"); return false; } public override bool MoveToNamespace(string name) { NotImplemented("MockXPathNavigator.MoveToNamespace"); return false; } public override bool MoveToNext() { NotImplemented("MockXPathNavigator.MoveToNext"); return false; } public override bool MoveToNextAttribute() { NotImplemented("MockXPathNavigator.MoveToNextAttribute"); return false; } public override bool MoveToNextNamespace(System.Xml.XPath.XPathNamespaceScope namespaceScope) { NotImplemented("MockXPathNavigator.MoveToNextNamespace"); return false; } public override bool MoveToParent() { NotImplemented("MockXPathNavigator.MoveToParent"); return false; } public override void MoveToRoot() { NotImplemented("MockXPathNavigator.MoveToRoot"); } public override string Name { get { NotImplemented("MockXPathNavigator.Name"); return null; } } public override string NamespaceURI { get { NotImplemented("MockXPathNavigator.NamespaceURI"); return null; } } public override System.Xml.XmlNameTable NameTable { get { NotImplemented("MockXPathNavigator.NameTable"); return null; } } public override System.Xml.XPath.XPathNodeType NodeType { get { NotImplemented("MockXPathNavigator.NodeType"); return XPathNodeType.All; } } public override string Prefix { get { NotImplemented("MockXPathNavigator.Prefix"); return null; } } public override string Value { get { NotImplemented("MockXPathNavigator.Value"); return null; } } public override string XmlLang { get { NotImplemented("MockXPathNavigator.XmlLang"); return null; } } public override bool MoveToPrevious() { NotImplemented("MockXPathNavigator.MoveToPrevious"); return false; } public override System.Xml.XPath.XPathNodeIterator Select(string xpath) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator Select(System.Xml.XPath.XPathExpression expr) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectAncestors(string name, string namespaceURI, bool matchSelf) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectAncestors(System.Xml.XPath.XPathNodeType type, bool matchSelf) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectChildren(string name, string namespaceURI) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectChildren(System.Xml.XPath.XPathNodeType type) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectDescendants(string name, string namespaceURI, bool matchSelf) { innerExecute(); return _iterator; } public override System.Xml.XPath.XPathNodeIterator SelectDescendants(System.Xml.XPath.XPathNodeType type, bool matchSelf) { innerExecute(); return _iterator; } private void innerExecute() { _selectCalls.Inc(); if (_expectedException != null) { throw _expectedException; } } #endregion #region Implementation of IMockObject public void NotImplemented(string methodName) { throw new NotImplementedException(methodName + " is currently not implemented."); } public string MockName { get { return name; } set { name = value; } } #endregion #region Implementation of IVerifiable public void Verify() { Verifier.Verify(this); } #endregion } } --- NEW FILE: MockXPathNodeIterator.cs --- using System; using System.Collections; using System.Xml.XPath; using DotNetMock; namespace DotNetMock.Framework.Xml.XPath { /// <summary> /// MockObject that extends the XPathNodeIterator class and implements the IMockObject interface /// </summary> public class MockXPathNodeIterator : XPathNodeIterator, IMockObject { private ExpectationCounter _moveNextCalls = new ExpectationCounter("MockXPathNodeIterator.MoveNextCalls"); private ArrayList _currentData = null; private int _currentPosition = 0; private string name = ""; /// <summary> /// Default Constructor. Sets the name of the object to "MockXPathNodeIterator" /// </summary> public MockXPathNodeIterator() { name = "MockXPathNodeIterator"; _currentData = new ArrayList(); } #region Mock Methods /// <summary> /// Sets the number of MoveNext() calls to expect /// </summary> /// <param name="count">Number of calls</param> public void SetExpectedMoveNextCalls( int count ) { _moveNextCalls.Expected = count; } /// <summary> /// Sets the collection of data to iterate over; /// </summary> /// <param name="data">Data to use</param> public void SetExpectedData( ArrayList data ) { _currentData = data; } #endregion #region Implementation of IMockObject /// <summary> /// Throws NotImplementedException() /// </summary> /// <param name="className">Method name that is not implemented</param> public void NotImplemented(string methodName) { throw new NotImplementedException(methodName + " is currently not implemented."); } /// <summary> /// Gets/Sets the Mock's name /// </summary> public string MockName { get { return name; } set { name = value; } } /// <summary> /// Verify the MockObject /// </summary> public void Verify() { Verifier.Verify( this ); } #endregion #region Overrides of XPathNodeIterator /// <summary> /// Clones the current XPathNodeIterator. Currently not implemented. /// </summary> /// <returns>Clone of the current XPathNodeIterator</returns> public override System.Xml.XPath.XPathNodeIterator Clone() { NotImplemented("MockXPathNodeIterator.Clone"); return null; } /// <summary> /// Moves to the next node in the selected set. /// </summary> /// <returns>True/False if there this is a valid move</returns> public override bool MoveNext() { _moveNextCalls.Inc(); if (_currentPosition < _currentData.Count) { _currentPosition++; return true; } else { return false; } } /// <summary> /// Gets the index of the alst node in the selected set of nodes. /// </summary> public override int Count { get { return _currentData.Count; } } /// <summary> /// Gets the Navigator position on the current node. /// </summary> public override System.Xml.XPath.XPathNavigator Current { get { return (XPathNavigator)_currentData[_currentPosition - 1]; } } /// <summary> /// Gets the index of the current position in the selected set of nodes. /// </summary> public override int CurrentPosition { get { return _currentPosition; } } #endregion } } |
From: <gc...@us...> - 2003-04-07 00:41:12
|
Update of /cvsroot/dotnetmock/dotnetmock/VisualStudioTemplates/CSharpProjectItems/LocalProjectItems/Code In directory sc8-pr-cvs1:/tmp/cvs-serv23705/Code Log Message: Directory /cvsroot/dotnetmock/dotnetmock/VisualStudioTemplates/CSharpProjectItems/LocalProjectItems/Code added to the repository |
From: <gc...@us...> - 2003-04-07 00:40:58
|
Update of /cvsroot/dotnetmock/dotnetmock/VisualStudioTemplates/CSharpProjectItems/LocalProjectItems In directory sc8-pr-cvs1:/tmp/cvs-serv23574/LocalProjectItems Log Message: Directory /cvsroot/dotnetmock/dotnetmock/VisualStudioTemplates/CSharpProjectItems/LocalProjectItems added to the repository |
From: <gc...@us...> - 2003-04-07 00:40:30
|
Update of /cvsroot/dotnetmock/dotnetmock/lib In directory sc8-pr-cvs1:/tmp/cvs-serv23394/lib Log Message: Directory /cvsroot/dotnetmock/dotnetmock/lib added to the repository |
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock Modified Files: AbstractExpectation.cs AbstractExpectationCollection.cs AssemblyInfo.cs DotNetMock.csproj ExpectationArrayList.cs ExpectationBool.cs ExpectationCounter.cs ExpectationString.cs ExpectationType.cs ExpectationValue.cs IExpectation.cs IExpectationCollection.cs IVerifiable.cs MockObject.cs NullObject.cs ReturnValue.cs Verifier.cs verifyException.cs Log Message: Comments and multiple changes Index: AbstractExpectation.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/AbstractExpectation.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** AbstractExpectation.cs 13 Jan 2003 04:03:56 -0000 1.8 --- AbstractExpectation.cs 1 Apr 2003 01:43:56 -0000 1.9 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; *************** *** 16,22 **** /// </summary> protected string name = null; - /// <summary> /// Default Constructor for AbstractExpectation /// </summary> /// <param name="name">Name of this Expectation</param> --- 65,77 ---- /// </summary> protected string name = null; /// <summary> /// Default Constructor for AbstractExpectation + /// </summary> + protected AbstractExpectation() + { + this.name = "AbstractExpectation"; + } + /// <summary> + /// Constructor for AbstractExpectation that sets the name of the Expectation /// </summary> /// <param name="name">Name of this Expectation</param> Index: AbstractExpectationCollection.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/AbstractExpectationCollection.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** AbstractExpectationCollection.cs 7 Feb 2003 03:13:40 -0000 1.7 --- AbstractExpectationCollection.cs 1 Apr 2003 01:43:56 -0000 1.8 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Collections; *************** *** 11,17 **** --- 60,71 ---- public abstract class AbstractExpectationCollection : AbstractExpectation, IExpectationCollection { + /// <summary> /// Default Constructor /// </summary> + protected AbstractExpectationCollection() : base() {} + /// <summary> + /// Constructor that takes in the name of the Expectation Collection + /// </summary> /// <param name="name">Name for AbstractExpectationCollection</param> protected AbstractExpectationCollection(string name) : base(name) {} *************** *** 20,34 **** /// </summary> /// <param name="actual">Values to check</param> ! abstract protected void CheckImmediateValues(object actual); /// <summary> /// Returns Actual Collection /// </summary> /// <returns>Actual Collection</returns> ! abstract public IList ActualCollection {get;} /// <summary> /// Returns Expected Collection /// </summary> /// <returns>Expected Collection</returns> ! abstract public IList ExpectedCollection {get;} /// <summary> /// Adds value to actual collection --- 74,88 ---- /// </summary> /// <param name="actual">Values to check</param> ! protected abstract void CheckImmediateValues(object actual); /// <summary> /// Returns Actual Collection /// </summary> /// <returns>Actual Collection</returns> ! public abstract IList ActualCollection {get;} /// <summary> /// Returns Expected Collection /// </summary> /// <returns>Expected Collection</returns> ! public abstract IList ExpectedCollection {get;} /// <summary> /// Adds value to actual collection *************** *** 89,93 **** /// Adds several values to the expected collection /// </summary> ! /// <param name="actualMany">Values to add</param> public void AddExpectedMany(object[] expectedMany) { --- 143,147 ---- /// Adds several values to the expected collection /// </summary> ! /// <param name="expectedMany">Values to add</param> public void AddExpectedMany(object[] expectedMany) { *************** *** 100,104 **** /// Adds several values to the expected collection /// </summary> ! /// <param name="actualMany">Values to add</param> public void AddExpectedMany(IEnumerable expectedMany) { --- 154,158 ---- /// Adds several values to the expected collection /// </summary> ! /// <param name="expectedMany">Values to add</param> public void AddExpectedMany(IEnumerable expectedMany) { *************** *** 112,116 **** /// Adds several values to the expected collection /// </summary> ! /// <param name="actualMany">Values to add</param> public void AddExpectedMany(IList expectedMany) { --- 166,170 ---- /// Adds several values to the expected collection /// </summary> ! /// <param name="expectedMany">Values to add</param> public void AddExpectedMany(IList expectedMany) { *************** *** 125,129 **** public override void ClearActual() { ! this.ExpectedCollection.Clear(); } /// <summary> --- 179,183 ---- public override void ClearActual() { ! this.ActualCollection.Clear(); } /// <summary> *************** *** 135,151 **** } /// <summary> - /// Sets expectations to nothing - /// </summary> - public override void ExpectNothing() - { - ClearExpected(); - this.HasExpectations = true; - } - /// <summary> /// Verifies expectation collection /// </summary> public override void Verify() { ! NUnit.Framework.Assertion.AssertEquals(this.ExpectedCollection.Count, this.ActualCollection.Count); for (int i = 0; i < this.ActualCollection.Count; i++) { --- 189,197 ---- } /// <summary> /// Verifies expectation collection /// </summary> public override void Verify() { ! NUnit.Framework.Assertion.AssertEquals("Expectation Count's do not equal.", this.ExpectedCollection.Count, this.ActualCollection.Count); for (int i = 0; i < this.ActualCollection.Count; i++) { Index: AssemblyInfo.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/AssemblyInfo.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** AssemblyInfo.cs 25 Mar 2003 03:02:07 -0000 1.7 --- AssemblyInfo.cs 1 Apr 2003 01:43:56 -0000 1.8 *************** *** 7,11 **** [assembly:CLSCompliant(true)] ! // Marks COM Visibility to false. we don't want COM clients to use this assembly [assembly:ComVisible(false)] // --- 7,11 ---- [assembly:CLSCompliant(true)] ! // Marks COM Visibility to false. We don't want COM clients to use this assembly [assembly:ComVisible(false)] // Index: DotNetMock.csproj =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/DotNetMock.csproj,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** DotNetMock.csproj 11 Mar 2003 22:45:34 -0000 1.10 --- DotNetMock.csproj 1 Apr 2003 01:43:56 -0000 1.11 *************** *** 138,141 **** --- 138,146 ---- /> <File + RelPath = "IMockObject.cs" + SubType = "Code" + BuildAction = "Compile" + /> + <File RelPath = "IVerifiable.cs" SubType = "Code" Index: ExpectationArrayList.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationArrayList.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ExpectationArrayList.cs 13 Jan 2003 04:03:57 -0000 1.8 --- ExpectationArrayList.cs 1 Apr 2003 01:43:56 -0000 1.9 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + namespace DotNetMock { *************** *** 44,48 **** int size = _actualArrayList.Count; NUnit.Framework.Assertion.Assert(_expectedArrayList.Count >= size); ! NUnit.Framework.Assertion.AssertEquals(_expectedArrayList[size -1], actual); } } --- 93,97 ---- int size = _actualArrayList.Count; NUnit.Framework.Assertion.Assert(_expectedArrayList.Count >= size); ! NUnit.Framework.Assertion.AssertEquals(_expectedArrayList[size - 1], actual); } } Index: ExpectationBool.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationBool.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ExpectationBool.cs 26 Feb 2003 17:18:18 -0000 1.1 --- ExpectationBool.cs 1 Apr 2003 01:43:56 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; *************** *** 46,51 **** public bool Actual { ! get { return _actualBool; } ! set { _actualBool = value;} } /// <summary> --- 95,110 ---- public bool Actual { ! get ! { ! return _actualBool; ! } ! set ! { ! _actualBool = value; ! if (ShouldCheckImmediate) ! { ! Verify(); ! } ! } } /// <summary> Index: ExpectationCounter.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationCounter.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ExpectationCounter.cs 7 Feb 2003 03:13:41 -0000 1.8 --- ExpectationCounter.cs 1 Apr 2003 01:43:56 -0000 1.9 *************** *** 1,3 **** ! namespace DotNetMock { using System; using NUnit.Framework; --- 1,53 ---- ! /* ! * ============================================================================ ! * The Apache Software License, Version 1.1 ! * ============================================================================ ! * ! * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. ! * ! * Redistribution and use in source and binary forms, with or without modifica- ! * tion, are permitted provided that the following conditions are met: ! * ! * 1. Redistributions of source code must retain the above copyright notice, ! * this list of conditions and the following disclaimer. ! * ! * 2. 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. ! * ! * 3. The end-user documentation included with the redistribution, if any, must ! * include the following acknowledgment: "This product includes software ! * developed by the Apache Software Foundation (http://www.apache.org/)." ! * Alternately, this acknowledgment may appear in the software itself, if ! * and wherever such third-party acknowledgments normally appear. ! * ! * 4. The names "log4j" and "Apache Software Foundation" must not be used to ! * endorse or promote products derived from this software without prior ! * written permission. For written permission, please contact ! * ap...@ap.... ! * ! * 5. Products derived from this software may not be called "Apache", nor may ! * "Apache" appear in their name, without prior written permission of the ! * Apache Software Foundation. ! * ! * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 ! * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, ! * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- ! * DING, 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. ! * ! * This software consists of voluntary contributions made by many individuals ! * on behalf of the Apache Software Foundation. For more information on the ! * Apache Software Foundation, please see <http://www.apache.org/>. ! * ! */ ! ! namespace DotNetMock ! { using System; using NUnit.Framework; Index: ExpectationString.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationString.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** ExpectationString.cs 7 Feb 2003 03:13:41 -0000 1.6 --- ExpectationString.cs 1 Apr 2003 01:43:56 -0000 1.7 *************** *** 1,5 **** namespace DotNetMock { - using System; /// <summary> /// Expectation String implementation. Extends <c>AbstractExpectaion</c> --- 1,53 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; namespace DotNetMock { /// <summary> /// Expectation String implementation. Extends <c>AbstractExpectaion</c> *************** *** 10,13 **** --- 58,66 ---- private string _actualString = null; private string _expectedString = null; + + /// <summary> + /// Default Constructor for ExpectationString. Set the name for this Expectation + /// </summary> + /// <param name="name">Name of this Expectation</param> public ExpectationString(string name) : base(name) { *************** *** 27,30 **** --- 80,87 ---- { this._actualString = value; + if (ShouldCheckImmediate) + { + Verify(); + } } } Index: ExpectationType.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationType.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ExpectationType.cs 26 Feb 2003 17:18:19 -0000 1.1 --- ExpectationType.cs 1 Apr 2003 01:43:56 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: ExpectationValue.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationValue.cs,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** ExpectationValue.cs 26 Mar 2003 03:14:48 -0000 1.11 --- ExpectationValue.cs 1 Apr 2003 01:43:56 -0000 1.12 *************** *** 1,5 **** namespace DotNetMock { - using System; /// <summary> /// Expectation Value implementation. Extends <c>AbstractExpectation</c> --- 1,54 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + + using System; namespace DotNetMock { /// <summary> /// Expectation Value implementation. Extends <c>AbstractExpectation</c> *************** *** 11,15 **** private Object _expectedValue = null; ! public ExpectationValue(string name) : base(name) { ClearActual(); } --- 60,69 ---- private Object _expectedValue = null; ! /// <summary> ! /// Default Constructor for ExpectationValue. Set the name for this Expectation ! /// </summary> ! /// <param name="name">Name of this Expectation</param> ! public ExpectationValue(string name) : base(name) ! { ClearActual(); } Index: IExpectation.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/IExpectation.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IExpectation.cs 13 Jan 2003 04:03:57 -0000 1.2 --- IExpectation.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,5 **** namespace DotNetMock { - using System; /// <summary> /// Interface that all expectation implement. Also implements the Verifiable interface --- 1,54 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; + namespace DotNetMock { /// <summary> /// Interface that all expectation implement. Also implements the Verifiable interface Index: IExpectationCollection.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/IExpectationCollection.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IExpectationCollection.cs 13 Jan 2003 04:03:57 -0000 1.2 --- IExpectationCollection.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,6 **** namespace DotNetMock { - using System; - using System.Collections; /// <summary> /// IExpectationCollection interface. Interface for all collection based Expectations. Implements <c>IExpectation</c> interface --- 1,55 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; + using System.Collections; + namespace DotNetMock { /// <summary> /// IExpectationCollection interface. Interface for all collection based Expectations. Implements <c>IExpectation</c> interface *************** *** 22,31 **** /// Adds a Collection that implements the IEnumerable interface to actual collection /// </summary> ! /// <param name="actualMany"></param> void AddActualMany(IEnumerable actualMany); /// <summary> /// Adds the elements of an object that implements IList to the actual collection /// </summary> ! /// <param name="actualMany"></param> void AddActualMany(IList actualMany); --- 71,80 ---- /// Adds a Collection that implements the IEnumerable interface to actual collection /// </summary> ! /// <param name="actualMany">Enumerator full of objects to add to the actual collection</param> void AddActualMany(IEnumerable actualMany); /// <summary> /// Adds the elements of an object that implements IList to the actual collection /// </summary> ! /// <param name="actualMany">List of objects to add to the actual collection</param> void AddActualMany(IList actualMany); *************** *** 33,52 **** /// Adds object to expected collection /// </summary> ! /// <param name="expected"></param> void AddExpected(object expected); /// <summary> /// Adds an array of objects to expected collection /// </summary> ! /// <param name="expectedMany"></param> void AddExpectedMany(object[] expectedMany); /// <summary> /// Adds a Collection that implements the IEnumerable interface to expected collection /// </summary> ! /// <param name="expectedMany"></param> void AddExpectedMany(IEnumerable expectedMany); /// <summary> /// Adds the elements of an object that implements IList to the expected collection /// </summary> ! /// <param name="expectedMany"></param> void AddExpectedMany(IList expectedMany); } --- 82,101 ---- /// Adds object to expected collection /// </summary> ! /// <param name="expected">Object to add to the expected collection</param> void AddExpected(object expected); /// <summary> /// Adds an array of objects to expected collection /// </summary> ! /// <param name="expectedMany">Objects to add to the expected collection</param> void AddExpectedMany(object[] expectedMany); /// <summary> /// Adds a Collection that implements the IEnumerable interface to expected collection /// </summary> ! /// <param name="expectedMany">Enumerator full of objects to add to the expected collection</param> void AddExpectedMany(IEnumerable expectedMany); /// <summary> /// Adds the elements of an object that implements IList to the expected collection /// </summary> ! /// <param name="expectedMany">IList to add to the expected collection</param> void AddExpectedMany(IList expectedMany); } Index: IVerifiable.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/IVerifiable.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IVerifiable.cs 13 Jan 2003 04:03:57 -0000 1.2 --- IVerifiable.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + namespace DotNetMock { Index: MockObject.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/MockObject.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** MockObject.cs 26 Mar 2003 03:14:48 -0000 1.10 --- MockObject.cs 1 Apr 2003 01:43:56 -0000 1.11 *************** *** 1,14 **** namespace DotNetMock { - using System; - using NUnit.Framework; /// <summary> ! /// Base Mock Object. All custom Mock Objects should extend this object. /// </summary> /// <remarks/> - - // TODO: Extend MarshalByRefObject to take care of remoting issues. [Serializable()] ! public class MockObject : MarshalByRefObject, IVerifiable { /// <summary> --- 1,62 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + + using System; + using NUnit.Framework; + namespace DotNetMock { /// <summary> ! /// Base Mock Object. All custom Mock Objects can extend this object. /// </summary> /// <remarks/> [Serializable()] ! public class MockObject : MarshalByRefObject, IMockObject { /// <summary> *************** *** 34,39 **** /// </summary> /// <param name="message">Message to display on failure.</param> ! /// <param name="object1">First Object.</param> ! /// <param name="object2">Second Object.</param> public void AssertEquals(string message, Object expectedObject, Object actualObject) { --- 82,89 ---- /// </summary> /// <param name="message">Message to display on failure.</param> ! /// <param name="expectedObject">First Object.</param> ! /// <param name="actualObject">Second Object.</param> ! // TODO: Remove in version 0.5 ! [Obsolete("Use NUnit.Framework.Assertion.AssertEquals instead.")] public void AssertEquals(string message, Object expectedObject, Object actualObject) { *************** *** 53,56 **** --- 103,108 ---- /// <param name="message">Message to display on failure.</param> /// <param name="condition">Condition to evaluate.</param> + // TODO: Remove in version 0.5 + [Obsolete("Use NUnit.Framework.Assertion.Assert instead.")] public void AssertTrue(string message, bool condition) { *************** *** 61,64 **** --- 113,118 ---- /// </summary> /// <param name="message">Message to display.</param> + // TODO: Remove in version 0.5 + [Obsolete("Use NUnit.Framework.Assertion.Fail instead.")] public void Fail(string message) { *************** *** 72,75 **** --- 126,145 ---- Verifier.Verify(this); } + + /// <summary> + /// Gets/Sets the Name of the Mock Object + /// </summary> + public string MockName + { + get + { + return name; + } + set + { + name = value; + } + } + } } Index: NullObject.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/NullObject.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NullObject.cs 26 Feb 2003 17:18:21 -0000 1.1 --- NullObject.cs 1 Apr 2003 01:43:56 -0000 1.2 *************** *** 1,5 **** namespace DotNetMock { ! using System; /// <summary> /// This represents a Null Object. --- 1,55 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; + namespace DotNetMock { ! /// <summary> /// This represents a Null Object. *************** *** 10,17 **** private string _name; public NullObject() { _name = "null"; } ! public NullObject(string name) { _name = name; } --- 60,75 ---- private string _name; + /// <summary> + /// Default Constructor. Sets the name of this object to "null" + /// </summary> public NullObject() { _name = "null"; } ! /// <summary> ! /// Default Constructor for NullObject. Set the name for this Object ! /// </summary> ! /// <param name="name">Name of this Object</param> ! public NullObject(string name) ! { _name = name; } *************** *** 40,43 **** --- 98,115 ---- { return _name.GetHashCode(); + } + /// <summary> + /// Gets/Sets the name of this Null Object + /// </summary> + public string Name + { + get + { + return _name; + } + set + { + _name = value; + } } } Index: ReturnValue.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ReturnValue.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** ReturnValue.cs 13 Jan 2003 04:03:57 -0000 1.4 --- ReturnValue.cs 1 Apr 2003 01:43:56 -0000 1.5 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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 + ... [truncated message content] |
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock/Dynamic/Predicates Modified Files: AndPredicate.cs IsAnything.cs IsCloseTo.cs IsEqual.cs IsEqualIgnoreCase.cs IsEqualIgnoreWhiteSpace.cs IsIn.cs IsMatch.cs IsNull.cs IsTypeOf.cs NotEqual.cs NotIn.cs NotNull.cs NotPredicate.cs OrPredicate.cs Predicate.cs Log Message: Comments and multiple changes Index: AndPredicate.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/AndPredicate.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** AndPredicate.cs 30 Oct 2002 04:16:33 -0000 1.1 --- AndPredicate.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IsAnything.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsAnything.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsAnything.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsAnything.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IsCloseTo.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsCloseTo.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsCloseTo.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsCloseTo.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Globalization; Index: IsEqual.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsEqual.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsEqual.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsEqual.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IsEqualIgnoreCase.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsEqualIgnoreCase.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsEqualIgnoreCase.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsEqualIgnoreCase.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Globalization; Index: IsEqualIgnoreWhiteSpace.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsEqualIgnoreWhiteSpace.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsEqualIgnoreWhiteSpace.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsEqualIgnoreWhiteSpace.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Text; Index: IsIn.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsIn.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsIn.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsIn.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IsMatch.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsMatch.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsMatch.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsMatch.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Text.RegularExpressions; Index: IsNull.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsNull.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsNull.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsNull.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IsTypeOf.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/IsTypeOf.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** IsTypeOf.cs 30 Oct 2002 04:16:33 -0000 1.1 --- IsTypeOf.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: NotEqual.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/NotEqual.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NotEqual.cs 30 Oct 2002 04:16:33 -0000 1.1 --- NotEqual.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: NotIn.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/NotIn.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NotIn.cs 30 Oct 2002 04:16:33 -0000 1.1 --- NotIn.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: NotNull.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/NotNull.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NotNull.cs 30 Oct 2002 04:16:33 -0000 1.1 --- NotNull.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: NotPredicate.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/NotPredicate.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NotPredicate.cs 30 Oct 2002 04:16:33 -0000 1.1 --- NotPredicate.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: OrPredicate.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/OrPredicate.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** OrPredicate.cs 30 Oct 2002 04:16:33 -0000 1.1 --- OrPredicate.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: Predicate.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Predicates/Predicate.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Predicate.cs 30 Oct 2002 04:16:33 -0000 1.1 --- Predicate.cs 1 Apr 2003 01:43:57 -0000 1.2 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework Modified Files: DotNetMock.Framework.csproj Log Message: Comments and multiple changes Index: DotNetMock.Framework.csproj =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/DotNetMock.Framework.csproj,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** DotNetMock.Framework.csproj 26 Mar 2003 03:14:49 -0000 1.4 --- DotNetMock.Framework.csproj 1 Apr 2003 01:43:57 -0000 1.5 *************** *** 133,136 **** --- 133,141 ---- /> <File + RelPath = "Xml\MockXmlValidatingReader.cs" + SubType = "Code" + BuildAction = "Compile" + /> + <File RelPath = "Xml\XPath\MockXPathNavigable.cs" SubType = "Code" |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Examples/MailingList In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Examples/MailingList Modified Files: MailingListTests.cs Log Message: Comments and multiple changes Index: MailingListTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Examples/MailingList/MailingListTests.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MailingListTests.cs 26 Mar 2003 03:14:49 -0000 1.3 --- MailingListTests.cs 1 Apr 2003 01:43:57 -0000 1.4 *************** *** 28,32 **** _mockCommand = new MockCommand(); _mockReader = new MockDataReader(); ! _mockConnection.SetupCommand(_mockCommand); } private void setGeneralExpectations() --- 28,32 ---- _mockCommand = new MockCommand(); _mockReader = new MockDataReader(); ! _mockConnection.SetExpectedCommand(_mockCommand); } private void setGeneralExpectations() |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Xml/XPath In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework/Xml/XPath Modified Files: MockXPathNavigable.cs Log Message: Comments and multiple changes Index: MockXPathNavigable.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Xml/XPath/MockXPathNavigable.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockXPathNavigable.cs 11 Mar 2003 22:45:40 -0000 1.2 --- MockXPathNavigable.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Xml; |
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework/Data Modified Files: MockCommand.cs MockDataParameter.cs MockDataParameterCollection.cs MockDataReader.cs MockDbConnection.cs MockTransaction.cs Log Message: Comments and multiple changes Index: MockCommand.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockCommand.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MockCommand.cs 26 Mar 2003 03:14:49 -0000 1.3 --- MockCommand.cs 1 Apr 2003 01:43:57 -0000 1.4 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; Index: MockDataParameter.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataParameter.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MockDataParameter.cs 26 Mar 2003 03:14:49 -0000 1.3 --- MockDataParameter.cs 1 Apr 2003 01:43:57 -0000 1.4 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; Index: MockDataParameterCollection.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataParameterCollection.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MockDataParameterCollection.cs 26 Mar 2003 03:14:49 -0000 1.3 --- MockDataParameterCollection.cs 1 Apr 2003 01:43:57 -0000 1.4 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; Index: MockDataReader.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataReader.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** MockDataReader.cs 25 Mar 2003 02:39:57 -0000 1.3 --- MockDataReader.cs 1 Apr 2003 01:43:57 -0000 1.4 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; Index: MockDbConnection.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDbConnection.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDbConnection.cs 11 Mar 2003 22:45:39 -0000 1.2 --- MockDbConnection.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; *************** *** 10,27 **** public class MockDbConnection : MockObject, IDbConnection { ! private IDbCommand _command; private ExpectationCounter _closeCalls = new ExpectationCounter("MockDbConnection.CloseCalls"); private ExpectationCounter _createCalls = new ExpectationCounter("MockDbConnection.CreateCalls"); private ExpectationString _connectionString = new ExpectationString("MockDbConnection.ConnectionString"); private Exception _createCommandException = null; /// <summary> /// Default Constructor /// </summary> ! public MockDbConnection() { } - #region Mock Methods public void SetExpectedConnectionString(string connectionString) { --- 59,114 ---- public class MockDbConnection : MockObject, IDbConnection { ! private IDbCommand _command = null; private ExpectationCounter _closeCalls = new ExpectationCounter("MockDbConnection.CloseCalls"); private ExpectationCounter _createCalls = new ExpectationCounter("MockDbConnection.CreateCalls"); + private ExpectationCounter _openCalls = new ExpectationCounter("MockDbConnection.OpenCalls"); private ExpectationString _connectionString = new ExpectationString("MockDbConnection.ConnectionString"); private Exception _createCommandException = null; + + private ConnectionState _connectionState = ConnectionState.Closed; + private int _connectionTimeout = 0; /// <summary> /// Default Constructor /// </summary> ! public MockDbConnection() {} ! /// <summary> ! /// Constructor that sets the name of the Mock Object ! /// </summary> ! /// <param name="name">Name of the Mock Object</param> ! public MockDbConnection( string name ) : base( name ) {} ! ! #region Mock Methods ! ! /// <summary> ! /// Sets expected connection state for the State property ! /// </summary> ! /// <param name="state">ConnectionState to expect</param> ! public void SetExpectedConnectionState( ConnectionState state ) ! { ! _connectionState = state; ! } ! ! /// <summary> ! /// Sets expected number of Open() calls to expect ! /// </summary> ! /// <param name="openCalls">Number of calls to expect</param> ! public void SetExpectedOpenCalls( int openCalls ) { + _openCalls.Expected = openCalls; + } + /// <summary> + /// Sets expected connection timeout value for the ConnectionTimeout property + /// </summary> + /// <param name="timeout">Connection timeout to expect</param> + public void SetExpectedConnectionTimeout( int timeout ) + { + _connectionTimeout = timeout; } + /// <summary> + /// Set expected connection string for connection string property + /// </summary> + /// <param name="connectionString">String to use</param> public void SetExpectedConnectionString(string connectionString) { *************** *** 32,36 **** /// </summary> /// <param name="command">Command to return</param> ! public void SetupCommand(IDbCommand command) { _command = command; --- 119,123 ---- /// </summary> /// <param name="command">Command to return</param> ! public void SetExpectedCommand(IDbCommand command) { _command = command; *************** *** 87,90 **** --- 174,178 ---- public System.Data.IDbTransaction BeginTransaction() { + this.NotImplemented("MockDbConnection.BeginTransaction"); return null; } *************** *** 97,107 **** { _createCalls.Inc(); ! if (_createCommandException == null) { ! return _command; } else { ! throw _createCommandException; } } --- 185,200 ---- { _createCalls.Inc(); ! if (_createCommandException != null) { ! throw _createCommandException; ! } ! ! if (_command == null) ! { ! return new MockCommand(); } else { ! return _command; } } *************** *** 111,118 **** public void Open() { ! this.NotImplemented("MockDbConnection.Open"); } /// <summary> ! /// Increments CloseCalls counter /// </summary> public void Close() --- 204,211 ---- public void Open() { ! _openCalls.Inc(); } /// <summary> ! /// Increments CloseCalls counter /// </summary> public void Close() *************** *** 127,131 **** get { ! return new System.Data.ConnectionState(); } } --- 220,224 ---- get { ! return _connectionState; } } *************** *** 145,149 **** } /// <summary> ! /// Gets the name of the current database or the database to be used once a connection is open /// </summary> public string Database --- 238,242 ---- } /// <summary> ! /// Gets the name of the current database or the database to be used once a connection is open /// </summary> public string Database *************** *** 161,165 **** get { ! return 0; } } --- 254,258 ---- get { ! return _connectionTimeout; } } Index: MockTransaction.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockTransaction.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockTransaction.cs 11 Mar 2003 22:45:39 -0000 1.2 --- MockTransaction.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Data; |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Security/Principal In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework/Security/Principal Modified Files: MockIIdentity.cs MockIPrincipal.cs Log Message: Comments and multiple changes Index: MockIIdentity.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Security/Principal/MockIIdentity.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockIIdentity.cs 11 Mar 2003 22:45:39 -0000 1.2 --- MockIIdentity.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using DotNetMock; Index: MockIPrincipal.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Security/Principal/MockIPrincipal.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockIPrincipal.cs 11 Mar 2003 22:45:39 -0000 1.2 --- MockIPrincipal.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Collections; *************** *** 94,97 **** --- 143,150 ---- get { + if (_expectedIdentity == null) + { + return new MockIIdentity(); + } return _expectedIdentity; } |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework.Tests/Data Modified Files: MockDbConnectionTests.cs Log Message: Comments and multiple changes Index: MockDbConnectionTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data/MockDbConnectionTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDbConnectionTests.cs 11 Mar 2003 22:45:41 -0000 1.2 --- MockDbConnectionTests.cs 1 Apr 2003 01:43:57 -0000 1.3 *************** *** 1,3 **** --- 1,4 ---- using System; + using System.Data; using DotNetMock.Framework.Data; using NUnit.Framework; *************** *** 43,46 **** --- 44,66 ---- } [Test] + public void OpenCalls() + { + _mockConnection.SetExpectedOpenCalls(3); + _mockConnection.Open(); + _mockConnection.Open(); + _mockConnection.Open(); + _mockConnection.Verify(); + } + + [Test] + [ExpectedException(typeof(AssertionException))] + public void InvalidOpenCalls() + { + _mockConnection.SetExpectedOpenCalls(1); + _mockConnection.Open(); + _mockConnection.Open(); + _mockConnection.Verify(); + } + [Test] public void ConnectionString() { *************** *** 56,59 **** --- 76,129 ---- _mockConnection.ConnectionString = "DSN="; _mockConnection.Verify(); + } + [Test] + public void ValidConnectionState() + { + _mockConnection.SetExpectedConnectionState( ConnectionState.Open ); + Assertion.AssertEquals("ConnectionState does not equal.", ConnectionState.Open, _mockConnection.State); + } + [Test] + [ExpectedException(typeof(AssertionException))] + public void InValidConnectionState() + { + _mockConnection.SetExpectedConnectionState( ConnectionState.Closed ); + Assertion.AssertEquals("ConnectionState equals", ConnectionState.Open, _mockConnection.State); + } + [Test] + public void DefaultState() + { + Assertion.AssertEquals("ConnectionState does not equal.", ConnectionState.Closed, _mockConnection.State); + } + [Test] + public void DefaultTimeout() + { + Assertion.AssertEquals("Timeouts do not equal.", 0, _mockConnection.ConnectionTimeout); + } + [Test] + public void ValidTimeout() + { + _mockConnection.SetExpectedConnectionTimeout( 5 ); + Assertion.AssertEquals( "Timeouts do not equal.", 5, _mockConnection.ConnectionTimeout); + } + [Test] + [ExpectedException(typeof(AssertionException))] + public void InValidTimeout() + { + _mockConnection.SetExpectedConnectionTimeout( 5 ); + Assertion.AssertEquals( "Timeouts equal.", 0, _mockConnection.ConnectionTimeout ); + } + [Test] + [ExpectedException(typeof(System.Data.DataException))] + public void CreateCommandException() + { + _mockConnection.SetCreateCommandException( new System.Data.DataException() ); + _mockConnection.CreateCommand(); + } + [Test] + public void ValidCreateCommand() + { + MockCommand mockCMD = new MockCommand(); + _mockConnection.SetExpectedCommand( mockCMD ); + Assertion.AssertEquals("Commands do not equal.", mockCMD, _mockConnection.CreateCommand()); } } |
From: <gc...@us...> - 2003-04-01 01:44:03
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Security/Principal In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Framework.Tests/Security/Principal Modified Files: MockIIdentityTests.cs Log Message: Comments and multiple changes Index: MockIIdentityTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Security/Principal/MockIIdentityTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockIIdentityTests.cs 11 Mar 2003 22:45:41 -0000 1.2 --- MockIIdentityTests.cs 1 Apr 2003 01:43:58 -0000 1.3 *************** *** 10,13 **** --- 10,14 ---- { private MockIIdentity mockIIdentity = null; + [SetUp] public void Init() |
From: <gc...@us...> - 2003-04-01 01:44:02
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Generate In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock/Dynamic/Generate Modified Files: ClassGenerator.cs Log Message: Comments and multiple changes Index: ClassGenerator.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Generate/ClassGenerator.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ClassGenerator.cs 30 Oct 2002 04:16:32 -0000 1.2 --- ClassGenerator.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Collections; |
From: <gc...@us...> - 2003-04-01 01:44:02
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock.Tests Modified Files: AssemblyInfo.cs ExpectationArrayListTests.cs ExpectationBoolTests.cs ExpectationCounterTests.cs ExpectationStringTests.cs ExpectationValueTests.cs MockObjectTests.cs NullTests.cs Log Message: Comments and multiple changes Index: AssemblyInfo.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/AssemblyInfo.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** AssemblyInfo.cs 7 Oct 2002 00:09:45 -0000 1.1 --- AssemblyInfo.cs 1 Apr 2003 01:43:58 -0000 1.2 *************** *** 10,14 **** [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] - [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("")] [assembly: AssemblyCopyright("")] --- 10,13 ---- Index: ExpectationArrayListTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/ExpectationArrayListTests.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ExpectationArrayListTests.cs 25 Oct 2002 03:56:52 -0000 1.3 --- ExpectationArrayListTests.cs 1 Apr 2003 01:43:58 -0000 1.4 *************** *** 69,73 **** [Test] ! public void HasNotExpectations() { _expectationArrayList.AddActual("A"); --- 69,73 ---- [Test] ! public void HasNoExpectations() { _expectationArrayList.AddActual("A"); *************** *** 100,104 **** NUnit.Framework.Assertion.Fail("Should have thrown an exception."); } ! catch (NUnit.Framework.AssertionException ex) { } --- 100,104 ---- NUnit.Framework.Assertion.Fail("Should have thrown an exception."); } ! catch { } Index: ExpectationBoolTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/ExpectationBoolTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ExpectationBoolTests.cs 25 Oct 2002 03:02:26 -0000 1.2 --- ExpectationBoolTests.cs 1 Apr 2003 01:43:58 -0000 1.3 *************** *** 64,68 **** NUnit.Framework.Assertion.Fail("Should have thrown an exception."); } ! catch (NUnit.Framework.AssertionException ex) { } --- 64,68 ---- NUnit.Framework.Assertion.Fail("Should have thrown an exception."); } ! catch { } Index: ExpectationCounterTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/ExpectationCounterTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ExpectationCounterTests.cs 25 Oct 2002 03:02:26 -0000 1.2 --- ExpectationCounterTests.cs 1 Apr 2003 01:43:58 -0000 1.3 *************** *** 1,10 **** ! namespace DotNetMock.Tests { ! using System; ! using NUnit.Framework; ! ! ! /// <summary> ! /// Test case for ExpectationCounter ! /// </summary> [TestFixture] public class ExpectationCounterTests { --- 1,7 ---- ! using System; ! using NUnit.Framework; ! ! namespace DotNetMock.Tests ! { [TestFixture] public class ExpectationCounterTests { *************** *** 12,18 **** private ExpectationCounter _counter; - public ExpectationCounterTests(): base() {} - public ExpectationCounterTests(String name) : base() {} - [SetUp] public void SetUp() --- 9,12 ---- *************** *** 57,82 **** [Test] public void FailOnVerify() { _counter.Expected = 1; _counter.Inc(); ! ! try ! { ! _counter.Inc(); ! } ! catch(AssertionException ae) ! { ! Assertion.Fail("Should not have thrown an exception"); ! } ! ! try ! { ! _counter.Verify(); ! NUnit.Framework.Assertion.Fail("Should have thrown an exception."); ! } ! catch(AssertionException ae) ! { ! } } --- 51,61 ---- [Test] + [ExpectedException(typeof(AssertionException))] public void FailOnVerify() { _counter.Expected = 1; _counter.Inc(); ! _counter.Inc(); ! _counter.Verify(); } Index: ExpectationStringTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/ExpectationStringTests.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ExpectationStringTests.cs 25 Oct 2002 03:56:52 -0000 1.3 --- ExpectationStringTests.cs 1 Apr 2003 01:43:58 -0000 1.4 *************** *** 11,16 **** { ExpectationString _expectationString = null; - public ExpectationStringTests(string name) : base() {} - public ExpectationStringTests() : base() {} [SetUp] --- 11,14 ---- *************** *** 34,37 **** --- 32,36 ---- _expectationString.Actual = test1; NUnit.Framework.Assertion.AssertNotNull(_expectationString.Actual); + Assertion.AssertEquals(test1, _expectationString.Actual); _expectationString.ClearActual(); NUnit.Framework.Assertion.AssertNull(_expectationString.Actual); *************** *** 59,62 **** --- 58,62 ---- _expectationString.Expected = test3; NUnit.Framework.Assertion.AssertNotNull(_expectationString.Expected); + Assertion.AssertEquals(test3, _expectationString.Expected); NUnit.Framework.Assertion.Assert(_expectationString.HasExpectations); *************** *** 65,69 **** [Test] - [ExpectedException(typeof(AssertionException))] public void Verify() { --- 65,68 ---- *************** *** 75,79 **** _expectationString.Expected = test5; ! _expectationString.Verify(); _expectationString.Expected = test6; --- 74,84 ---- _expectationString.Expected = test5; ! try ! { ! _expectationString.Verify(); ! } ! catch ! { ! } _expectationString.Expected = test6; Index: ExpectationValueTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/ExpectationValueTests.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ExpectationValueTests.cs 25 Oct 2002 03:56:52 -0000 1.3 --- ExpectationValueTests.cs 1 Apr 2003 01:43:58 -0000 1.4 *************** *** 12,18 **** private ExpectationValue _expectationValue; - public ExpectationValueTests(string name) : base() {} - public ExpectationValueTests() : base() {} - [SetUp] public void SetUp() { --- 12,15 ---- Index: MockObjectTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/MockObjectTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockObjectTests.cs 25 Oct 2002 03:02:26 -0000 1.2 --- MockObjectTests.cs 1 Apr 2003 01:43:58 -0000 1.3 *************** *** 1,8 **** namespace DotNetMock.Tests { - using System; - using NUnit.Framework; - using DotNetMock; - /// <summary> /// Summary description for MockObjectTests. --- 1,9 ---- + + using System; + using NUnit.Framework; + using DotNetMock; + namespace DotNetMock.Tests { /// <summary> /// Summary description for MockObjectTests. *************** *** 14,28 **** [SetUp] ! public void SetUp() { _mockObject = new MockObject(); } ! [ExpectedException(typeof(NotImplementedException))] public void NotImplemented() { _mockObject.NotImplemented("Fake Class Name"); - NUnit.Framework.Assertion.Fail("Assertion Failed: NotImplemented"); - } --- 15,31 ---- [SetUp] ! public void Init() { _mockObject = new MockObject(); } ! [TearDown] ! public void Destroy() ! { ! _mockObject = null; ! } [ExpectedException(typeof(NotImplementedException))] public void NotImplemented() { _mockObject.NotImplemented("Fake Class Name"); } *************** *** 43,47 **** _mockObject.AssertEquals("", object1, object2); - NUnit.Framework.Assertion.Fail("Assertion Failed: testAssertFalse"); } --- 46,49 ---- *************** *** 57,61 **** { _mockObject.AssertTrue("", false); - throw new System.ApplicationException("Assertion Failed: testAssertFalse"); } --- 59,62 ---- *************** *** 65,77 **** { _mockObject.Fail("Failed"); - NUnit.Framework.Assertion.Fail("Assertion Failed: testFail"); } - - [Test] - public void Verify() - { - _mockObject.Verify(); - } - } } --- 66,70 ---- Index: NullTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Tests/NullTests.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** NullTests.cs 30 Oct 2002 04:16:33 -0000 1.3 --- NullTests.cs 1 Apr 2003 01:43:58 -0000 1.4 *************** *** 1,7 **** namespace DotNetMock.Tests { - using System; - using NUnit.Framework; - using DotNetMock; /// <summary> /// Summary description for Null Class. --- 1,8 ---- + using System; + using NUnit.Framework; + using DotNetMock; + namespace DotNetMock.Tests { /// <summary> /// Summary description for Null Class. *************** *** 11,37 **** { private NullObject _null = null; - - public NullTests(string name) : base() {} - public NullTests() : base() {} [SetUp] ! public void SetUp() { _null = new NullObject(); } [TearDown] ! public void TearDown() { _null = null; } [Test] ! public void Null() { ! NUnit.Framework.Assertion.AssertEquals("null", _null.ToString()); ! _null = new NullObject("Null Object"); ! NUnit.Framework.Assertion.AssertEquals("Null Object", _null.ToString()); NullObject null2 = new NullObject(); int int1 = 3; NUnit.Framework.Assertion.Assert(!_null.Equals(int1)); NUnit.Framework.Assertion.Assert(_null.Equals(null2)); } } --- 12,40 ---- { private NullObject _null = null; [SetUp] ! public void Init() { _null = new NullObject(); } [TearDown] ! public void Destroy() { _null = null; } [Test] ! public void NullObjectMethods() { ! Assertion.AssertEquals("null", _null.ToString()); ! _null.Name = "Null Object"; ! Assertion.AssertEquals("Null Object", _null.ToString()); NullObject null2 = new NullObject(); int int1 = 3; NUnit.Framework.Assertion.Assert(!_null.Equals(int1)); NUnit.Framework.Assertion.Assert(_null.Equals(null2)); + } + [Test] + public void NullHashCode() + { + Assertion.AssertEquals("null".GetHashCode(), _null.GetHashCode()); } } |
From: <gc...@us...> - 2003-04-01 01:44:02
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic In directory sc8-pr-cvs1:/tmp/cvs-serv20364/DotNetMock/Dynamic Modified Files: DynamicMock.cs IMock.cs IPredicate.cs Mock.cs Log Message: Comments and multiple changes Index: DynamicMock.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/DynamicMock.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** DynamicMock.cs 30 Oct 2002 04:16:32 -0000 1.2 --- DynamicMock.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using DotNetMock.Dynamic.Generate; Index: IMock.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/IMock.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IMock.cs 30 Oct 2002 04:16:32 -0000 1.2 --- IMock.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; Index: IPredicate.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/IPredicate.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IPredicate.cs 30 Oct 2002 04:16:32 -0000 1.2 --- IPredicate.cs 1 Apr 2003 01:43:56 -0000 1.3 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + namespace DotNetMock.Dynamic { Index: Mock.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/Dynamic/Mock.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Mock.cs 13 Jan 2003 04:03:57 -0000 1.3 --- Mock.cs 1 Apr 2003 01:43:56 -0000 1.4 *************** *** 1,2 **** --- 1,51 ---- + /* + * ============================================================================ + * The Apache Software License, Version 1.1 + * ============================================================================ + * + * Copyright (C) 1999 The Apache Software Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modifica- + * tion, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. 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. + * + * 3. The end-user documentation included with the redistribution, if any, must + * include the following acknowledgment: "This product includes software + * developed by the Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, if + * and wherever such third-party acknowledgments normally appear. + * + * 4. The names "log4j" and "Apache Software Foundation" must not be used to + * endorse or promote products derived from this software without prior + * written permission. For written permission, please contact + * ap...@ap.... + * + * 5. Products derived from this software may not be called "Apache", nor may + * "Apache" appear in their name, without prior written permission of the + * Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 + * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU- + * DING, 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. + * + * This software consists of voluntary contributions made by many individuals + * on behalf of the Apache Software Foundation. For more information on the + * Apache Software Foundation, please see <http://www.apache.org/>. + * + */ + using System; using System.Collections; |
From: <gc...@us...> - 2003-03-26 03:14:53
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data In directory sc8-pr-cvs1:/tmp/cvs-serv24995/DotNetMock.Framework/Data Modified Files: MockCommand.cs MockDataParameter.cs MockDataParameterCollection.cs Log Message: 1) Added 'virtual' to definition of verify() in MockObject 2) Fixed MockDataParameter verification Index: MockCommand.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockCommand.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockCommand.cs 11 Mar 2003 22:45:36 -0000 1.2 --- MockCommand.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 123,127 **** public void Prepare() { ! throw new NotImplementedException("Canceling a command is currently not implemented."); } /// <summary> --- 123,127 ---- public void Prepare() { ! throw new NotImplementedException("Prepare() is currently not implemented."); } /// <summary> Index: MockDataParameter.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataParameter.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDataParameter.cs 11 Mar 2003 22:45:37 -0000 1.2 --- MockDataParameter.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 10,14 **** { private ExpectationBool _nullable = new ExpectationBool("MockDataParameter.IsNullable"); ! private ExpectationString _parameterName = new ExpectationString("MockDataParameter.Name"); private ExpectationValue _parameterValue = new ExpectationValue("MockDataParameter.Value"); private ExpectationString _parameterSourceColumn = new ExpectationString("MockDataParameter.SourceColumn"); --- 10,14 ---- { private ExpectationBool _nullable = new ExpectationBool("MockDataParameter.IsNullable"); ! private ExpectationString _parameterName = new ExpectationString("MockDataParameter.ParameterName"); private ExpectationValue _parameterValue = new ExpectationValue("MockDataParameter.Value"); private ExpectationString _parameterSourceColumn = new ExpectationString("MockDataParameter.SourceColumn"); *************** *** 93,97 **** } - #region Implementation of IDataParameter --- 93,96 ---- *************** *** 117,124 **** get { ! return (DbType)_parameterType.Actual; } set { } } --- 116,131 ---- get { ! if (_parameterType.Actual == null) ! { ! return DbType.String; ! } ! else ! { ! return (DbType)_parameterType.Actual; ! } } set { + _parameterType.Actual = value; } } *************** *** 130,133 **** --- 137,144 ---- get { + if (_parameterValue.Actual == null) + { + return ""; + } return _parameterValue.Actual; } *************** *** 135,139 **** { _parameterValue.Actual = value; ! _parameterType.Actual = inferType(value); } } --- 146,153 ---- { _parameterValue.Actual = value; ! if (_parameterType.Actual == null) ! { ! _parameterType.Actual = inferType(value); ! } } } *************** *** 164,167 **** --- 178,182 ---- set { + } } *************** *** 177,180 **** --- 192,196 ---- set { + _parameterName.Actual = value; } } *************** *** 186,193 **** --- 202,218 ---- get { + if ( _parameterSourceColumn.Actual == null) + { + return ""; + } return _parameterSourceColumn.Actual; } set { + if (value == null) + { + _parameterSourceColumn.Actual = ""; + } + _parameterSourceColumn.Actual = value; } } Index: MockDataParameterCollection.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataParameterCollection.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDataParameterCollection.cs 11 Mar 2003 22:45:38 -0000 1.2 --- MockDataParameterCollection.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 3,6 **** --- 3,8 ---- using System.Collections; using System.Globalization; + using DotNetMock; + using NUnit.Framework; namespace DotNetMock.Framework.Data *************** *** 14,18 **** /// Internal collection of parameters. /// </summary> ! private ExpectationArrayList _parameterCollection = new ExpectationArrayList("MockDataParameterCollection.Tests"); /// <summary> /// Flag indicating read-only status. --- 16,21 ---- /// Internal collection of parameters. /// </summary> ! private ArrayList _actualCollection = new ArrayList(); ! private ArrayList _expectedCollection = new ArrayList(); /// <summary> /// Flag indicating read-only status. *************** *** 27,34 **** /// Default constructor /// </summary> ! public MockDataParameterCollection() ! { ! ! } /// <summary> /// Adds expected paramter to the expected collection --- 30,35 ---- /// Default constructor /// </summary> ! public MockDataParameterCollection() {} ! /// <summary> /// Adds expected paramter to the expected collection *************** *** 37,43 **** public void AddExpected(IDataParameter parameter) { ! _parameterCollection.AddExpected(parameter.ParameterName); } #region Implementation of IDataParameterCollection /// <summary> /// Removes a parameter from the Actual collection --- 38,45 ---- public void AddExpected(IDataParameter parameter) { ! _expectedCollection.Add(parameter); } #region Implementation of IDataParameterCollection + /// <summary> /// Removes a parameter from the Actual collection *************** *** 46,59 **** public void RemoveAt(string parameterName) { - IList actual = _parameterCollection.ActualCollection; if (!this.Contains(parameterName) ) { throw new ApplicationException("Parameter by that name cannot be found."); } ! for (int i = 0; i < actual.Count; i++) ! { ! if (actual[i].Equals(parameterName)) { ! this.RemoveAt(i); } } --- 48,61 ---- public void RemoveAt(string parameterName) { if (!this.Contains(parameterName) ) { throw new ApplicationException("Parameter by that name cannot be found."); } ! for (int i = 0; i < _actualCollection.Count; i++) ! { ! MockDataParameter mockDP = (MockDataParameter) _actualCollection[i]; ! if (mockDP.ParameterName.Equals(parameterName)) { ! _actualCollection.RemoveAt(i); } } *************** *** 67,75 **** { bool result = false; - IList actual = _parameterCollection.ActualCollection; ! for (int i = 0; i < actual.Count; i++) { ! if (actual[i].Equals(parameterName)) { result = true; --- 69,77 ---- { bool result = false; ! for (int i = 0; i < _actualCollection.Count; i++) { ! MockDataParameter mockDP = (MockDataParameter) _actualCollection[i]; ! if (mockDP.ParameterName.Equals(parameterName)) { result = true; *************** *** 90,98 **** } int index = 0; - IList actual = _parameterCollection.ActualCollection; ! for (int i = 0; i < actual.Count; i++) { ! if (actual[i].Equals(parameterName)) { index = i; --- 92,100 ---- } int index = 0; ! for (int i = 0; i < _actualCollection.Count; i++) { ! MockDataParameter mockDP = (MockDataParameter) _actualCollection[i]; ! if (mockDP.ParameterName.Equals(parameterName)) { index = i; *************** *** 108,118 **** get { ! IList actual = _parameterCollection.ActualCollection; ! return actual[IndexOf(parameterName)]; } set { ! IList actual = _parameterCollection.ActualCollection; ! actual[IndexOf(parameterName)] = value; } } --- 110,118 ---- get { ! return _actualCollection[IndexOf(parameterName)]; } set { ! _actualCollection[IndexOf(parameterName)] = value; } } *************** *** 126,131 **** public void RemoveAt(int index) { ! IList actual = _parameterCollection.ActualCollection; ! actual.RemoveAt(index); } /// <summary> --- 126,130 ---- public void RemoveAt(int index) { ! _actualCollection.RemoveAt(index); } /// <summary> *************** *** 160,165 **** public void Clear() { ! IList actual = _parameterCollection.ActualCollection; ! actual.Clear(); } /// <summary> --- 159,163 ---- public void Clear() { ! _actualCollection.Clear(); } /// <summary> *************** *** 180,184 **** public IDataParameter Add(string parameterName, string parameterValue) { ! Add(parameterName); return null; } --- 178,183 ---- public IDataParameter Add(string parameterName, string parameterValue) { ! MockDataParameter mockDP = new MockDataParameter( parameterName, parameterValue); ! _actualCollection.Add( mockDP ); return null; } *************** *** 190,194 **** public IDataParameter Add(IDataParameter value) { ! Add(value.ParameterName); return null; } --- 189,193 ---- public IDataParameter Add(IDataParameter value) { ! _actualCollection.Add( value ); return null; } *************** *** 201,205 **** public IDataParameter Add(string parameterName, DbType type) { ! Add(parameterName); return null; } --- 200,205 ---- public IDataParameter Add(string parameterName, DbType type) { ! MockDataParameter mockDP = new MockDataParameter( parameterName, type ); ! _actualCollection.Add( mockDP ); return null; } *************** *** 211,215 **** public int Add(object value) { ! _parameterCollection.AddActual(value); return 0; } --- 211,215 ---- public int Add(object value) { ! _actualCollection.Add( value ); return 0; } *************** *** 235,245 **** get { ! IList actual = _parameterCollection.ActualCollection; ! return (object)actual[index]; } set { ! IList actual = _parameterCollection.ActualCollection; ! actual[index] = (IDataParameter)value; } } --- 235,243 ---- get { ! return (object)_actualCollection[index]; } set { ! _actualCollection[index] = (IDataParameter)value; } } *************** *** 277,282 **** get { ! IList actual = _parameterCollection.ActualCollection; ! return actual.Count; } } --- 275,279 ---- get { ! return _actualCollection.Count; } } *************** *** 312,318 **** public System.Collections.IEnumerator GetEnumerator() { ! IList actual = _parameterCollection.ActualCollection; ! return actual.GetEnumerator(); } #endregion --- 309,343 ---- public System.Collections.IEnumerator GetEnumerator() { ! return _actualCollection.GetEnumerator(); ! } ! #endregion ! #region MockObject overrides ! public override void Verify() ! { ! if (_expectedCollection.Count != _actualCollection.Count) ! { ! Assertion.Fail("Expected Parameters count does not equal Actual Parameters count."); ! } ! ! for (int i = 0; i < _actualCollection.Count; i++) ! { ! MockDataParameter verify = new MockDataParameter(); ! IDataParameter actual = (IDataParameter)_actualCollection[i]; ! IDataParameter expected = (IDataParameter)_expectedCollection[i]; ! ! verify.SetExpectedName( expected.ParameterName ); ! verify.SetExpectedNullable( expected.IsNullable ); ! verify.SetExpectedSourceColumn( expected.SourceColumn ); ! verify.SetExpectedType( expected.DbType ); ! verify.SetExpectedValue( expected.Value.ToString() ); ! verify.ParameterName = actual.ParameterName; ! verify.IsNullable = actual.IsNullable; ! verify.SourceColumn = actual.SourceColumn; ! verify.DbType = actual.DbType; ! verify.Value = actual.Value; ! ! verify.Verify(); ! } } #endregion |
From: <gc...@us...> - 2003-03-26 03:14:53
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework In directory sc8-pr-cvs1:/tmp/cvs-serv24995/DotNetMock.Framework Modified Files: DotNetMock.Framework.csproj Log Message: 1) Added 'virtual' to definition of verify() in MockObject 2) Fixed MockDataParameter verification Index: DotNetMock.Framework.csproj =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/DotNetMock.Framework.csproj,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** DotNetMock.Framework.csproj 25 Mar 2003 03:02:08 -0000 1.3 --- DotNetMock.Framework.csproj 26 Mar 2003 03:14:49 -0000 1.4 *************** *** 78,81 **** --- 78,86 ---- Package = "{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}" /> + <Reference + Name = "nunit.framework" + AssemblyName = "nunit.framework" + HintPath = "..\lib\nunit.framework.dll" + /> </References> </Build> |
From: <gc...@us...> - 2003-03-26 03:14:53
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data In directory sc8-pr-cvs1:/tmp/cvs-serv24995/DotNetMock.Framework.Tests/Data Modified Files: MockCommandTests.cs MockDataParameterCollectionTests.cs Log Message: 1) Added 'virtual' to definition of verify() in MockObject 2) Fixed MockDataParameter verification Index: MockCommandTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data/MockCommandTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockCommandTests.cs 11 Mar 2003 22:45:40 -0000 1.2 --- MockCommandTests.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 90,94 **** _mockCmd.Parameters.Add(mockParameter); _mockCmd.Verify(); - NUnit.Framework.Assertion.AssertEquals(typeof(MockDataParameterCollection), _mockCmd.Parameters.GetType()); } [Test] --- 90,93 ---- Index: MockDataParameterCollectionTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data/MockDataParameterCollectionTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDataParameterCollectionTests.cs 11 Mar 2003 22:45:40 -0000 1.2 --- MockDataParameterCollectionTests.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 64,71 **** { _mockDataParameterCollection.Add("@inpID", "123456"); ! NUnit.Framework.Assertion.Assert(_mockDataParameterCollection.Contains("@inpID")); _mockDataParameterCollection.Add("@inpPassword", "password"); ! NUnit.Framework.Assertion.Assert(_mockDataParameterCollection.Contains("@inpID")); ! NUnit.Framework.Assertion.Assert(_mockDataParameterCollection.Contains("@inpPassword")); } --- 64,71 ---- { _mockDataParameterCollection.Add("@inpID", "123456"); ! NUnit.Framework.Assertion.Assert("Parameter @inpID not found - First", _mockDataParameterCollection.Contains("@inpID")); _mockDataParameterCollection.Add("@inpPassword", "password"); ! NUnit.Framework.Assertion.Assert("Parameter @inpID not found - Second", _mockDataParameterCollection.Contains("@inpID")); ! NUnit.Framework.Assertion.Assert("Parameter @inpPassword not found", _mockDataParameterCollection.Contains("@inpPassword")); } *************** *** 117,121 **** MockDataParameter mockDP = new MockDataParameter("@inpID", "123456"); _mockDataParameterCollection.Add(mockDP); ! NUnit.Framework.Assertion.AssertEquals("Parameters not equal", "@inpID", _mockDataParameterCollection["@inpID"]); } [Test] --- 117,121 ---- MockDataParameter mockDP = new MockDataParameter("@inpID", "123456"); _mockDataParameterCollection.Add(mockDP); ! NUnit.Framework.Assertion.AssertEquals("Parameters not equal", mockDP, _mockDataParameterCollection["@inpID"]); } [Test] |
From: <gc...@us...> - 2003-03-26 03:14:52
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Examples/MailingList In directory sc8-pr-cvs1:/tmp/cvs-serv24995/DotNetMock.Examples/MailingList Modified Files: MailingListTests.cs Log Message: 1) Added 'virtual' to definition of verify() in MockObject 2) Fixed MockDataParameter verification Index: MailingListTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Examples/MailingList/MailingListTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MailingListTests.cs 25 Mar 2003 02:39:57 -0000 1.2 --- MailingListTests.cs 26 Mar 2003 03:14:49 -0000 1.3 *************** *** 42,46 **** _mockCommand.SetExpectedParameter(new MockDataParameter("@email", _email)); _mockCommand.SetExpectedParameter(new MockDataParameter("@name", _name)); - setGeneralExpectations(); } private void setExpectationsForRemoveMember() --- 42,45 ---- |
From: <gc...@us...> - 2003-03-26 03:14:51
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock In directory sc8-pr-cvs1:/tmp/cvs-serv24995/DotNetMock Modified Files: ExpectationValue.cs MockObject.cs Log Message: 1) Added 'virtual' to definition of verify() in MockObject 2) Fixed MockDataParameter verification Index: ExpectationValue.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/ExpectationValue.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ExpectationValue.cs 7 Feb 2003 03:13:41 -0000 1.10 --- ExpectationValue.cs 26 Mar 2003 03:14:48 -0000 1.11 *************** *** 39,43 **** set { ! this._actualValue = (Object)value; if (ShouldCheckImmediate) { --- 39,43 ---- set { ! this._actualValue = value; if (ShouldCheckImmediate) { *************** *** 57,61 **** set { ! this._expectedValue = (Object)value; this.HasExpectations = true; } --- 57,61 ---- set { ! this._expectedValue = value; this.HasExpectations = true; } Index: MockObject.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/MockObject.cs,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** MockObject.cs 25 Mar 2003 03:02:08 -0000 1.9 --- MockObject.cs 26 Mar 2003 03:14:48 -0000 1.10 *************** *** 68,72 **** /// Verifies object. /// </summary> ! public void Verify() { Verifier.Verify(this); --- 68,72 ---- /// Verifies object. /// </summary> ! public virtual void Verify() { Verifier.Verify(this); |
From: <gc...@us...> - 2003-03-25 03:02:12
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework In directory sc8-pr-cvs1:/tmp/cvs-serv10579/DotNetMock.Framework Modified Files: DotNetMock.Framework.csproj Log Message: 1) Added [Serializable()] attribute to MockObject 2) Changed MockObject to extend from MarshalByRefObject 3) Added AssemblyInfo.cs to the DotNetMock.Framework assembly Index: DotNetMock.Framework.csproj =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/DotNetMock.Framework.csproj,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** DotNetMock.Framework.csproj 11 Mar 2003 22:45:35 -0000 1.2 --- DotNetMock.Framework.csproj 25 Mar 2003 03:02:08 -0000 1.3 *************** *** 83,86 **** --- 83,91 ---- <Include> <File + RelPath = "AssemblyInfo.cs" + SubType = "Code" + BuildAction = "Compile" + /> + <File RelPath = "Data\MockCommand.cs" SubType = "Code" |
From: <gc...@us...> - 2003-03-25 03:02:12
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock In directory sc8-pr-cvs1:/tmp/cvs-serv10579/DotNetMock Modified Files: AssemblyInfo.cs MockObject.cs Log Message: 1) Added [Serializable()] attribute to MockObject 2) Changed MockObject to extend from MarshalByRefObject 3) Added AssemblyInfo.cs to the DotNetMock.Framework assembly Index: AssemblyInfo.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/AssemblyInfo.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** AssemblyInfo.cs 13 Jan 2003 04:03:57 -0000 1.6 --- AssemblyInfo.cs 25 Mar 2003 03:02:07 -0000 1.7 *************** *** 34,38 **** // by using the '*' as shown below: ! [assembly: AssemblyVersion("0.3.0.*")] // --- 34,38 ---- // by using the '*' as shown below: ! [assembly: AssemblyVersion("0.4.0.*")] // Index: MockObject.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock/MockObject.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** MockObject.cs 13 Jan 2003 04:03:57 -0000 1.8 --- MockObject.cs 25 Mar 2003 03:02:08 -0000 1.9 *************** *** 9,13 **** // TODO: Extend MarshalByRefObject to take care of remoting issues. ! public class MockObject : IVerifiable { /// <summary> --- 9,14 ---- // TODO: Extend MarshalByRefObject to take care of remoting issues. ! [Serializable()] ! public class MockObject : MarshalByRefObject, IVerifiable { /// <summary> |
From: <gc...@us...> - 2003-03-25 02:40:00
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data In directory sc8-pr-cvs1:/tmp/cvs-serv3786/DotNetMock.Framework.Tests/Data Modified Files: MockDataReaderTests.cs Log Message: 1) Fixed indexing problem with MockDataReader 2) Added Visual Studio Templates 3) Modified build file to include test and InstallTemplates Index: MockDataReaderTests.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework.Tests/Data/MockDataReaderTests.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDataReaderTests.cs 11 Mar 2003 22:45:41 -0000 1.2 --- MockDataReaderTests.cs 25 Mar 2003 02:39:57 -0000 1.3 *************** *** 141,145 **** for (int i = 0; i <= 1; i++) { ! Assertion.AssertEquals("Items not equal.", "Row " + rowCount + ", Column " + i, _reader.GetValue(i + 1)); } rowCount++; --- 141,145 ---- for (int i = 0; i <= 1; i++) { ! Assertion.AssertEquals("Items not equal.", "Row " + rowCount + ", Column " + i, _reader.GetValue(i)); } rowCount++; *************** *** 158,162 **** for (int i = 0; i <= 1; i++) { ! Assertion.AssertEquals("Items not equal.", "Row " + rowCount + ", Column " + i, _reader[i + 1]); } rowCount++; --- 158,162 ---- for (int i = 0; i <= 1; i++) { ! Assertion.AssertEquals("Items not equal.", "Row " + rowCount + ", Column " + i, _reader[i]); } rowCount++; *************** *** 195,205 **** while (_reader.Read()) { ! Assertion.AssertEquals(0, _reader.GetInt32(1)); ! Assertion.AssertEquals(1, _reader.GetInt32(2)); } _reader.Verify(); } [Test] ! [ExpectedException(typeof(IndexOutOfRangeException))] public void GetIntFails() { --- 195,205 ---- while (_reader.Read()) { ! Assertion.AssertEquals(0, _reader.GetInt32(0)); ! Assertion.AssertEquals(1, _reader.GetInt32(1)); } _reader.Verify(); } [Test] ! [ExpectedException(typeof(IndexOutOfRangeException))] public void GetIntFails() { *************** *** 214,219 **** while (_reader.Read()) { ! Assertion.AssertEquals(0, _reader.GetInt32(0)); ! Assertion.AssertEquals(1, _reader.GetInt32(1)); } _reader.Verify(); --- 214,219 ---- while (_reader.Read()) { ! Assertion.AssertEquals(0, _reader.GetInt32(3)); ! Assertion.AssertEquals(1, _reader.GetInt32(4)); } _reader.Verify(); |
From: <gc...@us...> - 2003-03-25 02:40:00
|
Update of /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data In directory sc8-pr-cvs1:/tmp/cvs-serv3786/DotNetMock.Framework/Data Modified Files: MockDataReader.cs Log Message: 1) Fixed indexing problem with MockDataReader 2) Added Visual Studio Templates 3) Modified build file to include test and InstallTemplates Index: MockDataReader.cs =================================================================== RCS file: /cvsroot/dotnetmock/dotnetmock/DotNetMock.Framework/Data/MockDataReader.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MockDataReader.cs 11 Mar 2003 22:45:39 -0000 1.2 --- MockDataReader.cs 25 Mar 2003 02:39:57 -0000 1.3 *************** *** 175,179 **** throw _getException; } ! return _rows[_currentRow, i - 1]; } /// <summary> --- 175,179 ---- throw _getException; } ! return _rows[_currentRow, i]; } /// <summary> *************** *** 426,430 **** if (_schemaTable.Columns[i].ColumnName.Equals(name)) { ! return i + 1; } } --- 426,430 ---- if (_schemaTable.Columns[i].ColumnName.Equals(name)) { ! return i; } } |