add brain-dead simple unit test to netwerk/protocol/http

RESOLVED WONTFIX

Status

()

Core
Networking: HTTP
RESOLVED WONTFIX
11 years ago
11 years ago

People

(Reporter: davel, Unassigned)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

11 years ago
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.
(Reporter)

Comment 1

11 years ago
Created attachment 231440 [details] [diff] [review]
brain-dead simple unit test
Attachment #231440 - Flags: review?(darin)
(Reporter)

Comment 2

11 years ago
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.
Attachment #231440 - Attachment is obsolete: true
Attachment #231526 - Flags: review?(darin)
Attachment #231440 - Flags: review?(darin)
(Reporter)

Comment 3

11 years ago
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?

Comment 4

11 years ago
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.
(Reporter)

Comment 5

11 years ago
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?
I think support for writing C++ unit tests would be good - not all functionality can be tested using javascript.
(Reporter)

Updated

11 years ago
Assignee: davel → nobody
(Reporter)

Comment 7

11 years ago
Comment on attachment 231526 [details] [diff] [review]
brain-dead unit test for netwerk/protocol/http

abandoning this effort
Attachment #231526 - Flags: review?(darin.moz)
(Reporter)

Comment 8

11 years ago
someone else will take up the unit testing efforts
Status: NEW → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.