Vote UpVote

Testing Cross Cutting Concerns

Craig Stuntz's Weblog – So imagine you’ve been asked to implement the following requirement: When a to-do list item is marked as complete, the CompletedOn date time property shall be set to the current time. That doesn’t sound so hard to implement, but how can I test it? I don’t know precisely what the value of the CompletedOn property "should be" since I don’t know precisely when the Complete setter will run. Method #1: Fuzzy Logic One option would be to see if the value is "close enough": var todo = new TodoItem("Test item"); var testStart = DateTime.Now; todo.Complete = true; var testStop ...
Favorite? Off-Topic? Craig Stuntz @ 2011-10-05 17:34


Visits: 472
Votes: 1
Favorites: 0
Off-Topic: 4

Visits by Source

User Actions

Users who voted for this posting

Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News


Please login or register to use this functionality.
(click on this box to dismiss)