While at the agile2006 conference, I worked with some attendees and we wrote one very basic unit test for nsHttpConnectionInfo::SetOriginServer() I'd like to land the test on trunk.
Created attachment 231440 [details] [diff] [review] brain-dead simple unit test
Created attachment 231526 [details] [diff] [review] brain-dead unit test for netwerk/protocol/http new version - don't specify path of static library. debug build did not complete without this change.
ok - I need some help with this patch. 1) it does not run on windows. I suspect I need to add the ".exe" to the SIMPLE_PROGRAMS target, and run from $(DIST)/bin so it finds the libraries. Anything else? 2) the executable is copied to $(DIST)/bin. Do I need to make sure it is not included in the release bits? If so, how?
dave: what does this unit test buy us? we don't really have good support from the build system for creating executables that link to internal functions like this.
I believe unit-style tests written in c++ are one type of test that should be supported by some sort of harness in our build system, so that creating new unit tests is easy. I intended this unit test to serve as an mechanism to discover how to add such support. I have the feeling that there are lots of philosophical and abstract technical discussions that may need to happen regarding unit tests, and that comments in this bug are not the right forum for such discussions. But I don't want to abandon this attempt completely until those discussions are complete. I'm willing to put in another day or two of effort to get this test to work. Do you think that is a reasonable time period, and if so, where should I look to figure out what the next set of changes should be?
Comment on attachment 231526 [details] [diff] [review] brain-dead unit test for netwerk/protocol/http abandoning this effort
Attachment #231526 - Flags: review?(darin.moz)
someone else will take up the unit testing efforts
Status: NEW → RESOLVED
Last Resolved: 12 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.