| Summary: | Unit testing suite for CDT project model | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Andrew Gvozdev <angvoz.dev> | ||||||
| Component: | cdt-build | Assignee: | cdt-build-inbox <cdt-build-inbox> | ||||||
| Status: | RESOLVED WONTFIX | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | jamesblackburn+eclipse | ||||||
| Version: | 6.0 | ||||||||
| Target Milestone: | --- | ||||||||
| Hardware: | All | ||||||||
| OS: | All | ||||||||
| Whiteboard: | |||||||||
| Bug Depends on: | 251962, 259964 | ||||||||
| Bug Blocks: | |||||||||
| Attachments: |
|
||||||||
|
Description
Andrew Gvozdev
Created attachment 117622 [details]
work-in-progress test suite
Here is the first version, please feel free to give any feedback. Number of files in the patch and the size of this thing corresponds to the complexity of project description model, so the patch is compressed. So far there are 3 test cases, one covers loading project description from sample .cproject, another creating/persisting project from build definition extension point, and third one creates and examines a Standard Make project. I'd say the tests are pretty thorough.
Btw, if you have NPE in the second test case, try to apply patch from bug 251962. Created attachment 118020 [details]
testExecutableCygwinGcc added
Refactored quite a bit and a new test case added. Still work in progress.
Hi Andrew, Just had a quick look at these tests. Unfortunately all of them are failing on current HEAD. (Also testProjectDescriptionSerializationFromFile appears to be missing some required resources.) Maybe there's a less brittle way of testing the project model funcationality? I think concrete tests for existing funcatinality / API is good, but tests which are implementation specific are likely to break more easily. This test suite is not nearly robust enough to sustain even miniscule changes in project model. It was more of a personal learning experience. |