You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(17) |
Aug
(6) |
Sep
(13) |
Oct
|
Nov
(2) |
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
|
Feb
(99) |
Mar
(42) |
Apr
(8) |
May
(17) |
Jun
(1) |
Jul
(1) |
Aug
(6) |
Sep
|
Oct
|
Nov
(26) |
Dec
|
| 2007 |
Jan
(1) |
Feb
(1) |
Mar
|
Apr
|
May
(21) |
Jun
|
Jul
(2) |
Aug
(21) |
Sep
(20) |
Oct
(33) |
Nov
(26) |
Dec
|
| 2008 |
Jan
(45) |
Feb
(8) |
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
(1) |
| 2009 |
Jan
|
Feb
(4) |
Mar
(1) |
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(9) |
Nov
(1) |
Dec
|
|
From: Heiko H. <rdr...@gm...> - 2007-09-11 11:09:37
|
Hello...
This is my first post and I already got some complains.. I know its a great start, but here we go...
Giving this code:
IDbObject foo = _mocks.NewMock<IDbObject>();
Stub.On(foo).SetProperty("Id");
Expect.Once.On(foo).SetProperty("Id");
foo.Id = 123;
_mocks.Verify.......;
It will generate an exception. The reason is that the above code will not satisfy my expection, since the stub which was defined 1st, will catch the assignment and so the expection will never be reached.
I think that an expection is much more important then a stub (Which is kinda a "Fallback" only).
For example... I want to test a controller for a view, and Verify that the events are propperly setup and processed...
I cannot create an implicit setup for the view (which creates the view and stubs all events), and then attach a real expection onto the view, that will allow me to sneak a mockEvent in, so i can fire it from the outside, and verify that the controler does its work.
I currently need to declare an implicit setup, which defines expections, since those can be removed by adding a "fake" Handler on the Mock e.g.:
//Inside CreateViewAndSetupBasicEvents Function
Expect.Once.On(mockedView).EventAdd("Save", Is.Anything);
//Inside my "real" test function...
mockedView.Save += null;
Expect.Once.On(mockedView).EventAdd("Save", Is.Anything)
.Will(MockEvent.Hookup(mockevent));
mockEvent.Raise();
Hope this makes sense....
I know i could "fix" it, by creating the view 1st and then adding the expections, and THEN finally adding all the stubs... But i kinda got attached to my setup functions so i can create and setup a basic mock with one call... Without that I would have to move the creation of the mock around, and I feel like i am "loosing" some clarity in my test, if I move to much into the "general" setup method.
--
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer
|
|
From: Mike C. <mik...@gm...> - 2007-08-17 14:21:17
|
On 17/08/07, Steve Mitcham <Ste...@ty...> wrote: > > I think development can go to using 2005 projects. As long as we have a > path to building a 1.1 version through the nant scripts I don't see the > usefulness in hamstringing the solution file to 2003. > > If there isn't much demand for 1.1 support, it may be in our interest to > create a branch for 1.1 development and point the HEAD branch squarely at > 2.0 only development I think a branch would be a better way to go. I haven't been running the nant script before checkin (I probably should have been, but I don't have a nant setup on my dev machines) and it's waaay too easy to break compatibility accidentally. Also, the version of Resharper that works with 2003 throws a fit at the #if NET20 guards we have in a couple of places; you have to comment them out to get any work done. Not very friendly. I'll post on the general list and see if anyone howls. |
|
From: Steve M. <Ste...@ty...> - 2007-08-17 13:41:15
|
I think development can go to using 2005 projects. As long as we have a path to building a 1.1 version through the nant scripts I don't see the usefulness in hamstringing the solution file to 2003. =20 If there isn't much demand for 1.1 support, it may be in our interest to create a branch for 1.1 development and point the HEAD branch squarely at 2.0 only development =20 From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Mike Mason Sent: Thursday, August 16, 2007 5:24 PM To: NMock2 Development Discussion Subject: Re: [NMock2-Dev] Mock Object Factory =20 On 8/16/07, Mike Capp <mik...@gm...> wrote: Also, we badly need to decide how much longer we're going to stay standardized on VS2003 solution/project files. I do still have access to VS2003, but that's not going to last forever, and having to make changes in there and patch them across to my main environment for testing is a) fragile and b) annoying. I think it's probably time to dump Studio 2003, if 2005 is able to produce .NET 1.1 binaries (or is that also no longer really useful for anyone?)=20 |
|
From: Mike M. <mg...@es...> - 2007-08-16 22:24:16
|
On 8/16/07, Mike Capp <mik...@gm...> wrote: > > Also, we badly need to decide how much longer we're going to stay > standardized on VS2003 solution/project files. I do still have access > to VS2003, but that's not going to last forever, and having to make > changes in there and patch them across to my main environment for > testing is a) fragile and b) annoying. I think it's probably time to dump Studio 2003, if 2005 is able to produce .NET 1.1 binaries (or is that also no longer really useful for anyone?) |
|
From: Charlie P. <ch...@po...> - 2007-08-16 19:47:59
|
Super! Thanks for the info. Charlie > -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On > Behalf Of Nat Pryce > Sent: Thursday, August 16, 2007 12:30 PM > To: NMock2 Development Discussion > Subject: Re: [NMock2-Dev] Mock Object Factory > > I originally developed it on both Windows and Linux with > Mono. There is a Gnu Makefile in the project that compiles > DLLs with Mono's C# compiler. > > --Nat > > On 16/08/07, Charlie Poole <ch...@po...> wrote: > > Does this project have a policy/vision/standard regarding > portability? > > Specifically, do you plan to make sure things work on Mono? > It seems > > like this would be a good time to decide on such things. > > > > Charlie > > > > > -----Original Message----- > > > From: nmo...@li... > > > [mailto:nmo...@li...] On Behalf Of > > > Mike Capp > > > Sent: Thursday, August 16, 2007 9:11 AM > > > To: NMock2 Development Discussion > > > Subject: Re: [NMock2-Dev] Mock Object Factory > > > > > > On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > > > > > > > > I've made the changes to the mock object factory code that > > > makes the > > > > generated type collection static to prevent run-away memory > > > usage with > > > > the mock objects, I'd like to get these changes into the > > > build if no > > > > one objects. We can investigate a solution with a more > > > robust proxy > > > > generator like Castle.DynamicProxy later. > > > > > > Do you have a rough performance comparison of old vs new > > > implementations for a reasonable-sized test corpus? > That's my only > > > real concern. > > > > > > > Finally, It would be nice if everyone interested in helping in > > > > reviving the development and getting a release out ping the > > > list so we > > > > can start the planning process. > > > > > > *ping* > > > > > > Also, we badly need to decide how much longer we're going to stay > > > standardized on VS2003 solution/project files. I do still have > > > access to VS2003, but that's not going to last forever, > and having > > > to make changes in there and patch them across to my main > > > environment for testing is a) fragile and > > > b) annoying. > > > > > > -------------------------------------------------------------- > > > ----------- > > > This SF.net email is sponsored by: Splunk Inc. > > > Still grepping through log files to find problems? Stop. > > > Now Search log events and configuration files using AJAX and a > > > browser. > > > Download your FREE copy of Splunk now >> http://get.splunk.com/ > > > _______________________________________________ > > > NMock-two-dev mailing list > > > NMo...@li... > > > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > > > > > > > > > > > > ---------------------------------------------------------------------- > > --- This SF.net email is sponsored by: Splunk Inc. > > Still grepping through log files to find problems? Stop. > > Now Search log events and configuration files using AJAX > and a browser. > > Download your FREE copy of Splunk now >> http://get.splunk.com/ > > _______________________________________________ > > NMock-two-dev mailing list > > NMo...@li... > > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > > > > -------------------------------------------------------------- > ----------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and > a browser. > Download your FREE copy of Splunk now >> > http://get.splunk.com/ _______________________________________________ > NMock-two-dev mailing list > NMo...@li... > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > |
|
From: Nat P. <nat...@gm...> - 2007-08-16 19:30:27
|
I originally developed it on both Windows and Linux with Mono. There is a Gnu Makefile in the project that compiles DLLs with Mono's C# compiler. --Nat On 16/08/07, Charlie Poole <ch...@po...> wrote: > Does this project have a policy/vision/standard regarding portability? > Specifically, do you plan to make sure things work on Mono? It seems like > this would be a good time to decide on such things. > > Charlie > > > -----Original Message----- > > From: nmo...@li... > > [mailto:nmo...@li...] On > > Behalf Of Mike Capp > > Sent: Thursday, August 16, 2007 9:11 AM > > To: NMock2 Development Discussion > > Subject: Re: [NMock2-Dev] Mock Object Factory > > > > On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > > > > > > I've made the changes to the mock object factory code that > > makes the > > > generated type collection static to prevent run-away memory > > usage with > > > the mock objects, I'd like to get these changes into the > > build if no > > > one objects. We can investigate a solution with a more > > robust proxy > > > generator like Castle.DynamicProxy later. > > > > Do you have a rough performance comparison of old vs new > > implementations for a reasonable-sized test corpus? That's my > > only real concern. > > > > > Finally, It would be nice if everyone interested in helping in > > > reviving the development and getting a release out ping the > > list so we > > > can start the planning process. > > > > *ping* > > > > Also, we badly need to decide how much longer we're going to > > stay standardized on VS2003 solution/project files. I do > > still have access to VS2003, but that's not going to last > > forever, and having to make changes in there and patch them > > across to my main environment for testing is a) fragile and > > b) annoying. > > > > -------------------------------------------------------------- > > ----------- > > This SF.net email is sponsored by: Splunk Inc. > > Still grepping through log files to find problems? Stop. > > Now Search log events and configuration files using AJAX and > > a browser. > > Download your FREE copy of Splunk now >> > > http://get.splunk.com/ _______________________________________________ > > NMock-two-dev mailing list > > NMo...@li... > > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > > > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > NMock-two-dev mailing list > NMo...@li... > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > |
|
From: Steve M. <Ste...@ty...> - 2007-08-16 18:39:24
|
I can schedule time any evening from Monday - Thursday after 8pm Central. -----Original Message----- From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Richard Holden Sent: Thursday, August 16, 2007 1:31 PM To: NMock2 Development Discussion Subject: [NMock2-Dev] IRC Channel/Future Planning Repeating myself since I hijacked an already hijacked thread: I have just registered 2 IRC channels on Freenode (irc.freenode.net) for NMock, #nmock2 and #nmock2-dev to facilitate quicker more interactive discussions on the NMock2 future. Also, for those with restrictions on access to IRC reply to this message with days and times that would work to have a live discussion about the future direction, standards, goals etc of NMock2, et. al. -Richard H. ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NMock-two-dev mailing list NMo...@li... https://lists.sourceforge.net/lists/listinfo/nmock-two-dev |
|
From: Richard H. <Ric...@qu...> - 2007-08-16 18:31:10
|
Repeating myself since I hijacked an already hijacked thread: I have just registered 2 IRC channels on Freenode (irc.freenode.net) for NMock, #nmock2 and #nmock2-dev to facilitate quicker more interactive discussions on the NMock2 future. Also, for those with restrictions on access to IRC reply to this message with days and times that would work to have a live discussion about the future direction, standards, goals etc of NMock2, et. al. -Richard H. |
|
From: Steve M. <Ste...@ty...> - 2007-08-16 18:27:51
|
Unfortunately, I'm not able to access IRC or any other IM networks when I'm at work. I get a little time in the evenings (CST) when I can log in to such a channel, but that would be after my kids go to bed. -----Original Message----- From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Richard Holden Sent: Thursday, August 16, 2007 1:25 PM To: NMock2 Development Discussion Subject: Re: [NMock2-Dev] Mock Object Factory > -----Original Message----- > From: nmo...@li...=20 > [mailto:nmo...@li...] On=20 > Behalf Of Charlie Poole > Sent: Thursday, August 16, 2007 11:10 AM > To: 'NMock2 Development Discussion' > Subject: Re: [NMock2-Dev] Mock Object Factory >=20 > Does this project have a policy/vision/standard regarding portability? > Specifically, do you plan to make sure things work on Mono?=20 > It seems like this would be a good time to decide on such things. >=20 > Charlie=20 >=20 I have just registered 2 IRC channels on Freenode (irc.freenode.net) for NMock, #nmock2 and #nmock2-dev to facilitate quicker more interactive discussions on the NMock2 future. -Richard H. ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NMock-two-dev mailing list NMo...@li... https://lists.sourceforge.net/lists/listinfo/nmock-two-dev |
|
From: Richard H. <Ric...@qu...> - 2007-08-16 18:25:08
|
> -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On > Behalf Of Charlie Poole > Sent: Thursday, August 16, 2007 11:10 AM > To: 'NMock2 Development Discussion' > Subject: Re: [NMock2-Dev] Mock Object Factory > > Does this project have a policy/vision/standard regarding portability? > Specifically, do you plan to make sure things work on Mono? > It seems like this would be a good time to decide on such things. > > Charlie > I have just registered 2 IRC channels on Freenode (irc.freenode.net) for NMock, #nmock2 and #nmock2-dev to facilitate quicker more interactive discussions on the NMock2 future. -Richard H. |
|
From: Charlie P. <ch...@po...> - 2007-08-16 17:10:05
|
Does this project have a policy/vision/standard regarding portability? Specifically, do you plan to make sure things work on Mono? It seems like this would be a good time to decide on such things. Charlie > -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On > Behalf Of Mike Capp > Sent: Thursday, August 16, 2007 9:11 AM > To: NMock2 Development Discussion > Subject: Re: [NMock2-Dev] Mock Object Factory > > On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > > > > I've made the changes to the mock object factory code that > makes the > > generated type collection static to prevent run-away memory > usage with > > the mock objects, I'd like to get these changes into the > build if no > > one objects. We can investigate a solution with a more > robust proxy > > generator like Castle.DynamicProxy later. > > Do you have a rough performance comparison of old vs new > implementations for a reasonable-sized test corpus? That's my > only real concern. > > > Finally, It would be nice if everyone interested in helping in > > reviving the development and getting a release out ping the > list so we > > can start the planning process. > > *ping* > > Also, we badly need to decide how much longer we're going to > stay standardized on VS2003 solution/project files. I do > still have access to VS2003, but that's not going to last > forever, and having to make changes in there and patch them > across to my main environment for testing is a) fragile and > b) annoying. > > -------------------------------------------------------------- > ----------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and > a browser. > Download your FREE copy of Splunk now >> > http://get.splunk.com/ _______________________________________________ > NMock-two-dev mailing list > NMo...@li... > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > |
|
From: Mike C. <mik...@gm...> - 2007-08-16 16:10:44
|
On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > > I've made the changes to the mock object factory code that makes the > generated type collection static to prevent run-away memory usage with the > mock objects, I'd like to get these changes into the build if no one > objects. We can investigate a solution with a more robust proxy generator > like Castle.DynamicProxy later. Do you have a rough performance comparison of old vs new implementations for a reasonable-sized test corpus? That's my only real concern. > Finally, It would be nice if everyone interested in helping in reviving the > development and getting a release out ping the list so we can start the > planning process. *ping* Also, we badly need to decide how much longer we're going to stay standardized on VS2003 solution/project files. I do still have access to VS2003, but that's not going to last forever, and having to make changes in there and patch them across to my main environment for testing is a) fragile and b) annoying. |
|
From: Steve M. <Ste...@ty...> - 2007-08-16 15:48:50
|
I've made the changes to the mock object factory code that makes the generated type collection static to prevent run-away memory usage with the mock objects, I'd like to get these changes into the build if no one objects. We can investigate a solution with a more robust proxy generator like Castle.DynamicProxy later. =20 This change fixes my issues, and should fix a least one of the bugs in the database, although I'll have to check those later. =20 Also, I'd like to add a nmock and nmock2 category for the defect list so we can cull out the defects that are logged against the old nmock. =20 Finally, It would be nice if everyone interested in helping in reviving the development and getting a release out ping the list so we can start the planning process. |
|
From: Mike M. <mg...@es...> - 2007-08-16 14:28:22
|
If anyone wants adding to the source forge committe list please let me know your sf id and I can add you. I don't have time to review patches but I'm confident about adding people, everyone on this list talks a lot me sense. On 8/15/07, Steve Mitcham <Ste...@ty...> wrote: > No worries, just letting the list know what is up. > > I wish I could go to an agile conference, but our customer is worlds > away from anything resembling agile. > > Just getting executable unit tests suites earlier in the development > cycle is my goal outside my own pet projects. > > -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On Behalf Of Steve > Freeman > Sent: Wednesday, August 15, 2007 2:51 PM > To: NMock2 Development Discussion > Subject: Re: [NMock2-Dev] NMock2 Release > > Sorry for the delay. I'm at the Agile conference this week. > > S. > On 15 Aug 2007, at 14:04, Steve Mitcham wrote: > > I'm in a position to help start up contributions. I've sent my > > contact > > info to Steve Freeman so I can be added to the list of > > contributors. My > > company is willing to fund a bit of development on this project and I > > can probably squeeze more in as our requirements add stuff. > > > > -----Original Message----- > > From: nmo...@li... > > [mailto:nmo...@li...] On Behalf Of > > Richard Holden > > Sent: Wednesday, August 15, 2007 11:21 AM > > To: NMock2 Development Discussion > > Subject: Re: [NMock2-Dev] NMock2 Release > > > > > >> BTW: Who is now resposible (the "owner") of this project? > >> the guys from thoughtworks? Richard you already offered to > >> take over this project, right? > >> > > > > Yes, I did offer to take over the project but I heard nothing back > > from > > anyone. I think we have had enough discussion and change to the code > > that a release is warrented, and I will do whatever I can to help that > > come about. > > > ------------------------------------------------------------------------ > - > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > NMock-two-dev mailing list > NMo...@li... > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > NMock-two-dev mailing list > NMo...@li... > https://lists.sourceforge.net/lists/listinfo/nmock-two-dev > |
|
From: Steve M. <Ste...@ty...> - 2007-08-16 13:23:17
|
There may not be explicit unit tests, but the test suite itself covers the expectation builder at 96% if you run the test suite through NCover. -----Original Message----- From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Mike Capp Sent: Thursday, August 16, 2007 8:05 AM To: NMock2 Development Discussion Subject: Re: [NMock2-Dev] Minor change I'd like to make The code itself (around line 256 of Internal/ExpectationBuilder.cs) is straightward; it's an easy fix, and would actually make things tidier because we wouldn't need overloads. The fact that this ~300-line class has no unit tests whatsoever is a little embarrassing... M. On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > There was some discussion a while ago on this issue. I'm not sure that > it ever got entered as a bug. I've been bit by it when dealing with > 'out' parameters (example: With(1,2,Is.Out) fails) > > I think that adding the matcher to the list using the coalescing > operator would be pretty readable > The following example is without having a chance to look at the code in > question, so I hope you get the gist > > expectations.Add(x as Matcher ?? Is.EqualTo(x)) ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NMock-two-dev mailing list NMo...@li... https://lists.sourceforge.net/lists/listinfo/nmock-two-dev |
|
From: Mike C. <mik...@gm...> - 2007-08-16 13:04:34
|
The code itself (around line 256 of Internal/ExpectationBuilder.cs) is straightward; it's an easy fix, and would actually make things tidier because we wouldn't need overloads. The fact that this ~300-line class has no unit tests whatsoever is a little embarrassing... M. On 16/08/07, Steve Mitcham <Ste...@ty...> wrote: > There was some discussion a while ago on this issue. I'm not sure that > it ever got entered as a bug. I've been bit by it when dealing with > 'out' parameters (example: With(1,2,Is.Out) fails) > > I think that adding the matcher to the list using the coalescing > operator would be pretty readable > The following example is without having a chance to look at the code in > question, so I hope you get the gist > > expectations.Add(x as Matcher ?? Is.EqualTo(x)) |
|
From: Steve M. <Ste...@ty...> - 2007-08-16 12:49:06
|
There was some discussion a while ago on this issue. I'm not sure that
it ever got entered as a bug. I've been bit by it when dealing with
'out' parameters (example: With(1,2,Is.Out) fails)
I think that adding the matcher to the list using the coalescing
operator would be pretty readable
The following example is without having a chance to look at the code in
question, so I hope you get the gist
expectations.Add(x as Matcher ?? Is.EqualTo(x))
-----Original Message-----
From: nmo...@li...
[mailto:nmo...@li...] On Behalf Of Mike
Capp
Sent: Thursday, August 16, 2007 5:43 AM
To: nmo...@li...
Subject: [NMock2-Dev] Minor change I'd like to make
Currently, ExpectationBuilder's "With" and friends take either an
array of Matchers or an array of objects which are converted to
EqualMatchers.
The problem with this is that if I have a "With(1, 2, 3, 4, 5)"
expectation and I want to replace the 5 with some other Matcher, I
have to explicitly convert all of the other arguments to explicit
Matchers as well. There's no good reason for this as far as I can see,
and it's a usability regression from NMock1. I'd therefore like to
change this to allow Matchers and non-matchers to be mixed. Matchers
are used as is; non-Matchers are converted to EqualMatchers as they
are today.
The change wouldn't break anything that worked before unless a test
was explicitly expecting Matcher argument values, which isn't likely
to happen and is still expressible via Is.EqualTo(myMatcher) if it
does.
I appreciate that "if (x is Matcher) {} else {}" has an odour to it,
but I don't think that in itself justifies throwing the user off a
convenience cliff in this case.
Any objections?
Mike
------------------------------------------------------------------------
-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
NMock-two-dev mailing list
NMo...@li...
https://lists.sourceforge.net/lists/listinfo/nmock-two-dev
|
|
From: Mike C. <mik...@gm...> - 2007-08-16 10:43:08
|
Currently, ExpectationBuilder's "With" and friends take either an
array of Matchers or an array of objects which are converted to
EqualMatchers.
The problem with this is that if I have a "With(1, 2, 3, 4, 5)"
expectation and I want to replace the 5 with some other Matcher, I
have to explicitly convert all of the other arguments to explicit
Matchers as well. There's no good reason for this as far as I can see,
and it's a usability regression from NMock1. I'd therefore like to
change this to allow Matchers and non-matchers to be mixed. Matchers
are used as is; non-Matchers are converted to EqualMatchers as they
are today.
The change wouldn't break anything that worked before unless a test
was explicitly expecting Matcher argument values, which isn't likely
to happen and is still expressible via Is.EqualTo(myMatcher) if it
does.
I appreciate that "if (x is Matcher) {} else {}" has an odour to it,
but I don't think that in itself justifies throwing the user off a
convenience cliff in this case.
Any objections?
Mike
|
|
From: Steve M. <Ste...@ty...> - 2007-08-15 19:53:58
|
No worries, just letting the list know what is up. =20 I wish I could go to an agile conference, but our customer is worlds away from anything resembling agile. Just getting executable unit tests suites earlier in the development cycle is my goal outside my own pet projects. -----Original Message----- From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Steve Freeman Sent: Wednesday, August 15, 2007 2:51 PM To: NMock2 Development Discussion Subject: Re: [NMock2-Dev] NMock2 Release Sorry for the delay. I'm at the Agile conference this week. S. On 15 Aug 2007, at 14:04, Steve Mitcham wrote: > I'm in a position to help start up contributions. I've sent my =20 > contact > info to Steve Freeman so I can be added to the list of =20 > contributors. My > company is willing to fund a bit of development on this project and I > can probably squeeze more in as our requirements add stuff. > > -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On Behalf Of > Richard Holden > Sent: Wednesday, August 15, 2007 11:21 AM > To: NMock2 Development Discussion > Subject: Re: [NMock2-Dev] NMock2 Release > > >> BTW: Who is now resposible (the "owner") of this project? >> the guys from thoughtworks? Richard you already offered to >> take over this project, right? >> > > Yes, I did offer to take over the project but I heard nothing back =20 > from > anyone. I think we have had enough discussion and change to the code > that a release is warrented, and I will do whatever I can to help that > come about. ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NMock-two-dev mailing list NMo...@li... https://lists.sourceforge.net/lists/listinfo/nmock-two-dev |
|
From: Steve F. <st...@m3...> - 2007-08-15 19:50:32
|
Sorry for the delay. I'm at the Agile conference this week. S. On 15 Aug 2007, at 14:04, Steve Mitcham wrote: > I'm in a position to help start up contributions. I've sent my > contact > info to Steve Freeman so I can be added to the list of > contributors. My > company is willing to fund a bit of development on this project and I > can probably squeeze more in as our requirements add stuff. > > -----Original Message----- > From: nmo...@li... > [mailto:nmo...@li...] On Behalf Of > Richard Holden > Sent: Wednesday, August 15, 2007 11:21 AM > To: NMock2 Development Discussion > Subject: Re: [NMock2-Dev] NMock2 Release > > >> BTW: Who is now resposible (the "owner") of this project? >> the guys from thoughtworks? Richard you already offered to >> take over this project, right? >> > > Yes, I did offer to take over the project but I heard nothing back > from > anyone. I think we have had enough discussion and change to the code > that a release is warrented, and I will do whatever I can to help that > come about. |
|
From: Steve M. <Ste...@ty...> - 2007-08-15 18:04:54
|
I'm in a position to help start up contributions. I've sent my contact info to Steve Freeman so I can be added to the list of contributors. My company is willing to fund a bit of development on this project and I can probably squeeze more in as our requirements add stuff. -----Original Message----- From: nmo...@li... [mailto:nmo...@li...] On Behalf Of Richard Holden Sent: Wednesday, August 15, 2007 11:21 AM To: NMock2 Development Discussion Subject: Re: [NMock2-Dev] NMock2 Release > BTW: Who is now resposible (the "owner") of this project? > the guys from thoughtworks? Richard you already offered to=20 > take over this project, right? >=20 Yes, I did offer to take over the project but I heard nothing back from anyone. I think we have had enough discussion and change to the code that a release is warrented, and I will do whatever I can to help that come about. -Richard H. ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ NMock-two-dev mailing list NMo...@li... https://lists.sourceforge.net/lists/listinfo/nmock-two-dev |
|
From: Richard H. <Ric...@qu...> - 2007-08-15 16:21:37
|
> BTW: Who is now resposible (the "owner") of this project? > the guys from thoughtworks? Richard you already offered to > take over this project, right? > Yes, I did offer to take over the project but I heard nothing back from anyone. I think we have had enough discussion and change to the code that a release is warrented, and I will do whatever I can to help that come about. -Richard H. |
|
From: <pin...@gm...> - 2007-07-25 05:58:07
|
hi, i am highly interested in a new release of NMock2 (maybe a RC2?). I am esp. interested in the event stuff included now. What is necessary to roll out a RC2 this week? How can I help? BTW: Who is now resposible (the "owner") of this project? the guys from thoughtworks? Richard you already offered to take over this project, right? regards, seb -- Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kanns mit allen: http://www.gmx.net/de/go/multimessenger |
|
From: Richard H. <Ric...@qu...> - 2007-07-16 19:44:24
|
When might we expect a new release of NMock2? -Richard Holden |
|
From: Steve M. <Ste...@ty...> - 2007-05-29 19:24:56
|
-- and the With clause is potentially misleading since it's not doing
matching
I think that the difference in the syntax is enough that there wouldn't
be confusion that this is more of an action than an expectation. Is
there a different term for that part of the syntax that you would use?
-----Original Message-----
From: nmo...@li...
[mailto:nmo...@li...] On Behalf Of Mike
Capp
Sent: Tuesday, May 29, 2007 1:36 PM
To: Steve Mitcham
Cc: nmo...@li...
Subject: Re: [NMock2-Dev] Fwd: [TDD] Nmock verify
Hi Steve,
Not dead, it just seems that way... I had a few reports from QA on
Friday that needed looking at, and a bank holiday yesterday.
I'm splitting your patch into smaller, more specific commits so that
it's easier for people to see what's changing and why. The ordering
bugfix is already committed, and I'm looking at the event-raising
feature now. (The MockObjectFactory will go last since it'll probably
be the most contentious.)
A few questions/comments:
* MockObject.RemoveEventHandler was only removing handlers if it
didn't contain them. Can I assume this was a simple copy-and-paste-o,
rather than anything more subtle?
* The signature for IMockObject.RaiseEvent looks a bit fuzzier than it
needs to be. We do very little with events here, so I'm not too
informed on the subject, but my NET 1.1 docs say that an event handler
delegate must have a signature of the form "void Foo(object sender,
EventArgs e)". Should RaiseEvent take one argument e, of type
(assignable to) EventArgs, and pass (this, e) to each handler? Or have
things been relaxed in NET 2.0?
* Not convinced that MockObject.RaiseEvent should throw if no handlers
have been attached. This isn't the behaviour of 'real' events.
* The patch's Fire.Event(name).On(mock).With(args) follows the same
syntactic pattern as Expect or Stub. I'm not sure we need that same
level of flexibility, particularly if the (object, EventArgs) rule for
handler delegates is still in force, and the With clause is
potentially misleading since it's not doing matching. Also, this
pattern only allows events to be raised out of a clear blue sky. Would
it be also be useful to support events firing in response to a mocked
method call? If so, how about implementing it as an IAction instead?
F'rinstance:
// Out of a clear blue sky
new EventAction("Beep", beepArgs).RaiseOn(myMock); // or add
syntactic sugar to taste
// Triggered by method call
Expect.Once.On(myMock)
.Method("Foo").WithAnyArguments
.Will(Raise.Event("Beep", beepArgs), Return.Value("something"));
Looks like a straightforward tweak, and it composes nicely with other
actions.
* I'm going to need your nmock2.key at some point; it wasn't in the
patch or zip. I'm pretty sure that's the last of the missing files,
though.
cheers
Mike
------------------------------------------------------------------------
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
NMock-two-dev mailing list
NMo...@li...
https://lists.sourceforge.net/lists/listinfo/nmock-two-dev
|