Commit Graph

412 Commits

Author SHA1 Message Date
Kosta 5553a538c5 tweak CMakeLists.txt 2013-08-05 12:57:29 +02:00
Kosta ce441a9ba5 initial checkin of cmake and travis config files 2013-08-05 12:43:51 +02:00
Phil Nash b80280f428 Tidied up reporting of missing assertions in test cases
- also removed basic reporter from approval test
2013-07-26 19:19:44 +01:00
Phil Nash 28d3881ff9 Merged TestCaseTracker and SectionTracker and introduced TestCaseTracker::Guard 2013-07-25 08:07:55 +01:00
Phil Nash ee647f5099 Removed displaced RunningTest class 2013-07-25 07:49:00 +01:00
Phil Nash 9aff9aa328 Integrated new section tracker.
- also pass extra section to reporter - one for each test case - ignore it in headers
  (this is so we know a test case has restarted)
- significant effect on regression test due to change of ordering of sections
- fixes infinite loop issue
2013-07-24 19:13:08 +01:00
Phil Nash 6a484fdb02 Reworked SectionTracker and moved into own header 2013-07-23 18:48:36 +01:00
Phil Nash 372a6c6fed Small fixes and started new section tracking code 2013-07-23 08:15:34 +01:00
Phil Nash ad7445d33c build 5
- added throw() to streambuf destructor overrides (#182)
2013-07-02 08:49:29 +01:00
Phil Nash 3907559896 build 4 2013-07-01 19:02:29 +01:00
Phil Nash 109f46a48b Fixed broken test 2013-07-01 19:00:55 +01:00
Phil Nash 066a6388d6 Fix for #179 2013-07-01 18:45:19 +01:00
Phil Nash 4b5e008b20 guard NOMINMAX definition (windows) 2013-06-29 20:31:17 +01:00
Phil Nash cd688300b0 Build 2 2013-06-29 12:11:32 +01:00
Phil Nash 5d26ca1af7 Static assertion for && and || expressions 2013-06-29 12:07:33 +01:00
Phil Nash a9b346b14d Removed line numbers from approval tests of xml too 2013-06-29 12:04:38 +01:00
Phil Nash 40b8c7794c Removed line numbers from approval tests 2013-06-29 11:59:49 +01:00
Phil Nash b5fd5a6496 INFO and CAPTURE are now scoped
- SCOPED_INFO and SCOPED_CAPTURE are now just aliases
2013-06-28 17:09:57 +01:00
Phil Nash 0d357302a0 INFOs only reset at assertion if consumed 2013-06-28 16:25:49 +01:00
Phil Nash 239fa28e46 Added run without -s to approvals 2013-06-28 16:23:14 +01:00
Phil Nash 47751e4df3 Approved [.] change 2013-06-28 16:07:42 +01:00
Phil Nash 9c39a5e8dd Support [.] as alias for [hide] 2013-06-28 16:05:13 +01:00
Phil Nash 235204393a Big merge from Integration
- now v1.0 build 1
2013-06-28 14:11:28 +01:00
Phil Nash 5b15c21c9c Fixed iTChRunner 2013-06-12 19:05:21 +01:00
Phil Nash c57ebc84b2 Approved latest changes 2013-06-05 08:20:34 +01:00
Phil Nash cb60d130f8 Runner -> RunContext, Runner2 -> Runner and fixed issue with processName 2013-06-05 08:18:52 +01:00
Phil Nash 2ed56c47a6 Removed legacy cli parser 2013-06-04 08:38:40 +01:00
Phil Nash aee9b75e37 Now fully switched over to Clara-based command line with modified args 2013-06-04 08:37:28 +01:00
Phil Nash 0514fe4f38 Got parseCommandLine ready to use new Clara (but not doing so yet) 2013-05-31 18:48:31 +01:00
Phil Nash c9f0f55451 Last changes to ConfigData names (for now) 2013-05-31 08:01:56 +01:00
Phil Nash 40e529740c Removed stream name from config 2013-05-29 19:06:25 +01:00
Phil Nash 3f184e22e8 ConfigData now looks virtually identical to the Clara test Config 2013-05-29 19:01:06 +01:00
Phil Nash 20ddb0055f ConfigData just keeps strings for test names/ specs/ tags (processed in Config actor) 2013-05-29 18:56:29 +01:00
Phil Nash c2ca80d9fb Config refactoring: split List enum into three bools 2013-05-29 18:42:46 +01:00
Phil Nash 3c3beb57c3 More config refactoring 2013-05-29 18:34:11 +01:00
Phil Nash be8fd82f20 Started nudging ConfigData towards new layout 2013-05-29 08:12:57 +01:00
Phil Nash ca9b92f8fa Most of system now uses Ptr<IConfig const> 2013-05-28 18:51:53 +01:00
Phil Nash e1459955f1 Refactoring towards interface based config 2013-05-28 18:39:32 +01:00
Phil Nash 10fa0593db Moved Clara into its (her?) own file 2013-05-27 10:52:58 +01:00
Phil Nash 1e547afe79 Tweaked some option names and added verbosity 2013-05-24 19:23:44 +01:00
Phil Nash ab6dd55fcf Clara: formatting and code tweaks 2013-05-23 19:01:10 +01:00
Phil Nash b7632659f5 Clara: Usage strings for args 2013-05-21 19:21:24 +01:00
Phil Nash ed79d726be Clara: support for positional arguments 2013-05-21 08:15:50 +01:00
Phil Nash 30cb460d42 Clara: added test for positional arg 2013-05-20 18:45:33 +01:00
Phil Nash 3dde25be7d Clara: support for binary functions 2013-05-20 18:40:51 +01:00
Phil Nash d44f2cf40f Added binding to free functions (and renamed hierarchy) 2013-05-20 08:31:12 +01:00
Phil Nash d4305377b7 Fixed inconsistency in reporting of _FALSE (negated) expressions 2013-05-17 19:35:33 +01:00
Phil Nash 374335fc84 Approved current output 2013-05-17 08:18:42 +01:00
Phil Nash 6574f639a3 Refactored CLI tests and converted main one into a scenario 2013-05-17 08:00:57 +01:00
Phil Nash 8d1100daa6 Clara: added -r option 2013-05-17 07:43:58 +01:00
Phil Nash 8333e644f2 Clara: some refactoring
- moved all internal stuff into Detail
- moved Parser out of CommandLine, encapsulates tokens.
- allow unused tokens to be feed into different CommandLine processors
2013-05-16 19:07:50 +01:00
Phil Nash 58846c395c Clara: Added support for compact short opts (e.g. -peb) 2013-05-16 08:21:13 +01:00
Phil Nash 372a8b018d New CLI parser impl 2013-05-15 19:25:34 +01:00
Phil Nash 597ed1f79d handle TEST_CASE_METHOD macro consistently
- internally define INTERNAL_CATCH_TEST_CASE_METHOD
2013-05-14 19:31:21 +01:00
Phil Nash 0c5626962a test case for infinite loop 2013-05-13 08:20:45 +01:00
Phil Nash 11e55161e1 Some refactoring of Clara impl and experimental string based interface 2013-05-07 18:53:14 +01:00
Phil Nash e2f93b6507 Clara: Allow space separator, as well as : and = 2013-05-03 08:08:46 +01:00
Phil Nash a13ab71cbf Clara: Some renames and changed the addOption interface 2013-05-02 18:41:08 +01:00
Phil Nash ed45ceb786 Added support for binding to methods and generating usage strings.
Also renamed namespace to Clara
2013-05-01 19:01:48 +01:00
Phil Nash 46846a47f3 More CmdLine work
- Support for non string values
- Support for chaining parsers
2013-04-29 19:26:18 +01:00
Phil Nash 26ae11774b First draft of future opt parser lib 2013-04-27 12:26:13 +01:00
Phil Nash 8defc71e6d Build 38 2013-04-24 19:10:02 +01:00
Phil Nash 1309da2b55 approved changes relating to no-return functions 2013-04-24 18:51:34 +01:00
Phil Nash bf37e6879a Removed use of compiler specific techniques for denoting non-returning functions
- use if( Catch::isTrue( true) ) to guard throws instead
2013-04-23 20:52:49 +01:00
Phil Nash d0d4d93a6b Build 37
- string matchers work with NULLs
- removed stray CATCH_CONFIG_SFINAE for GCC 3
2013-04-23 08:02:48 +01:00
Phil Nash 06548a5b61 Fix for #144
- string matchers now work with NULLs
2013-04-23 07:59:56 +01:00
Phil Nash 471eba2c32 Build 36
- incorporation of pull request #154 to allow comparison with nullptr_t
- some compiler capability tweaks
2013-04-22 18:55:12 +01:00
Phil Nash 4dd3f68dd9 Compiler capabilities clean-up
- renamed CATCH_SFINAE -> CATCH_CONFIG_SFINAE
- moved variadic macros detection into catch_compiler_capabilities.h
2013-04-22 08:19:17 +01:00
Phil Nash dd52044374 Build 35
- non-SFINAE IsStreamInsertable
2013-04-20 23:20:05 +01:00
Phil Nash 003960dc90 Returned to older version of IsStreamable
- this time based on code from Martin Moene
https://gist.github.com/martinmoene/5418947#file-insertionopdetector-cpp
2013-04-20 23:12:17 +01:00
Phil Nash 19279250e8 Build 34
includes:
- SFINAE version of IsStreamable (where available)
- new Text class that replaces LineWrapper (internal)
- fix for spurious double exception reporting (#164)
2013-04-20 21:07:32 +01:00
Phil Nash 2666c96d4e Fixes issue #164
- Removed spurious (re-)throw when catching unexpected exception
2013-04-20 21:04:32 +01:00
Phil Nash b3acf45d70 Fully committed to new Text class.
- moved impl into .hpp
- replaced last few uses of LineWrapper with Text
- removed LineWrapper
2013-04-20 19:36:40 +01:00
Phil Nash d37a8e8f98 Revert "Refactored line wrapping in Text constructor a bit"
This reverts commit e43d4a2028.
2013-04-20 18:40:10 +01:00
Phil Nash e43d4a2028 Refactored line wrapping in Text constructor a bit 2013-04-20 18:37:42 +01:00
Phil Nash 54ca219aad Text class is now full replacement for LineWrap 2013-04-20 11:27:28 +01:00
Phil Nash 7059c6e1c3 Text class mostly working
- tabs not yet working
2013-04-19 19:08:32 +01:00
Phil Nash 052dc18c76 Remove SFINAE support for all unknown compilers 2013-04-18 07:40:19 +01:00
Phil Nash 5062d3e92b Added (conditional) SFINAE support.
Better streamable detection for toString using SFINAE (falls back to non-SFINAE version without)
2013-04-16 22:55:31 +01:00
Phil Nash 243f2d2caf build 33 2013-04-12 10:43:06 +01:00
Phil Nash 1ece38ed20 Moved legacy_reporter_adapter files back into internal 2013-04-08 21:36:08 +01:00
Phil Nash 3bd4241795 Fixed Junit issue with REQUIRE_THROWS
- As mentioned by @SebDyn in GitHub issue #5
2013-04-08 12:05:32 +01:00
Phil Nash 8764177c0e build 32 2013-04-08 11:50:41 +01:00
Phil Nash 7af7451f78 LegacyReporterAdapter unbundles INFO messages from assertion to mimic legacy behaviour
- Moved LegacyReporterAdapter out into its own file(s)
2013-04-08 11:44:03 +01:00
Phil Nash 12c16fff8d Build 31
- new Colour class
- Headers are wrapped, with special indentation for given/ when/ then
2013-04-05 20:58:01 +01:00
Phil Nash 4746caacaf LineWrapper can indent first line differently to subsequent lines
- use this to wrap Given/ When/ Then with indent after the :
2013-04-05 20:55:57 +01:00
Phil Nash a3703faa0a First cut of new Colour class (to replace TextColour) 2013-04-05 07:47:36 +01:00
Phil Nash 5c7d3d75cc build 30 2013-04-01 11:27:10 +01:00
Phil Nash 9d15d36748 Changed Xcode search paths for easier sharing of projects with Windows 2013-03-29 21:39:02 +00:00
Phil Nash e324d2829d Added -l tags
- which lists available tags.
- also improved formatting of -l for tests
2013-03-29 11:42:10 +00:00
Phil Nash d0df295c25 Added vector resizing example to BDD tests 2013-03-28 22:13:57 +00:00
Phil Nash 15fd032608 Use new line wrapper to show test case list, with tags, in columns 2013-03-28 22:13:31 +00:00
Phil Nash b052bd729a Refactored string wrapper
- to be much more flexible (writes to vector)
- fixed a couple of bugs
2013-03-27 19:08:16 +00:00
Phil Nash 016b063ae8 Line numbers changed and test added 2013-03-25 09:25:01 +00:00
Phil Nash 2927c240a1 Fixed line wrap bug
Added line wrap tests and modified wrap algo to wrap within words using a -
2013-03-25 09:20:51 +00:00
Phil Nash 29426b6359 Added vector resize test 2013-03-25 08:47:36 +00:00
Phil Nash 2e3c5fa2ad Addressed some warnings (mostly MSVC) 2013-03-25 08:46:48 +00:00
Phil Nash 6ba2057abd refactored toLower 2013-03-22 19:00:42 +00:00
Phil Nash bd7f797e09 build 27 2013-03-21 09:00:24 +00:00
Phil Nash 49d7ce40e8 Minor tidy up 2013-03-21 08:58:22 +00:00
Phil Nash 9390675260 Build 26 2013-03-16 20:21:51 +00:00
Phil Nash c0b698073e Initial support for variadic macros 2013-03-16 20:18:52 +00:00
Phil Nash 9c5bbab239 build 25 2013-03-13 20:54:19 +00:00
Phil Nash 37186a1d04 Added BDD macros
(Also includes regenerated files from previous commits)
2013-03-13 12:19:30 +00:00
Phil Nash 0db35c0f35 Cleaned up -Wpadded warning handling a bit more 2013-03-13 08:18:30 +00:00
Phil Nash dc2735c23d Removed some cruft and warnings 2013-03-13 08:04:50 +00:00
Phil Nash 7542685a2f Moved "no test cases matched" message to reporter 2013-03-12 19:06:40 +00:00
Phil Nash 6d56d71318 build 24 2013-03-12 18:49:37 +00:00
Phil Nash 32e70b2235 Fixes nil NSString issue reported in #159 2013-03-12 18:49:22 +00:00
Phil Nash 17479c6e49 Tag and test case name querying are now case insensitive 2013-03-12 18:47:53 +00:00
Phil Nash 3df6c0d1b4 Refactored ConsoleColour impl. Tweaked the (Windows) colours a bit.
Also fixed issue that would cause warnings on some compilers when doing REQUIRE( p ); where p is a pointer.
Moved to build 23
2013-03-11 18:38:29 +00:00
Phil Nash a04981b450 Build 22 2013-03-08 09:30:25 +00:00
Phil Nash 85dff2bce8 Added duplicate method warnings 2013-03-06 20:45:21 +01:00
Phil Nash 5de07c3a30 Removed unnecessary test 2013-03-06 20:41:02 +01:00
Phil Nash b7ff995e89 Tidied up some loose ends with reporting test cases and sections (now handles them as a single block).
This should fixes an issue where sections not being printed when they should be (and reverses a workaround where they were being printed too much)
2013-03-06 20:40:16 +01:00
Phil Nash 90b2bfec3d Patched issue where an assert before the first section can cause a set-fault (needs a better fix, though) 2013-03-04 15:06:31 +01:00
Phil Nash 767f1588dc Added StringMaker (for partially specialising string conversions), extended BDD macros and moved file/line info to top of message.
Re-enable ANSI colour by default - hopefully properly excluding Windows this time
2013-03-04 12:19:15 +01:00
Phil Nash ead139e094 Reverted ANSI colour change (it was failing for Windows)
Produced build 20
2013-02-19 19:59:04 +00:00
Phil Nash 10ed1e0e34 Handle section ends in the event of unexpected exceptions 2013-02-19 19:45:09 +00:00
Phil Nash 3f503851d7 Updated approval file 2013-02-19 18:51:46 +00:00
Phil Nash 35cb97f5e2 Cleaned up some stray tests 2013-02-19 18:45:06 +00:00
Phil Nash a8c6543bcc Merged Matcher changes to Objective-C bindings 2013-02-19 08:46:09 +00:00
Phil Nash d768b1b7f9 Fixed sticky INFO (which persisted across TEST_CASEs) from #152 and generated build 18 2013-02-04 00:05:16 +00:00
Phil Nash fb944f2b6b Updated message tests to reflect slightly changed semantics 2013-02-02 20:46:55 +00:00
Phil Nash 207b27b3c5 Changed the way info messages are handled.
This fixes issue with SCOPED_INFO and makes output more readable.
Needs some refactoring.
2013-02-02 19:58:04 +00:00
Phil Nash 67ccd8d74a Allows console line width to be configured (and defaults to 80).
Line wrap is at console width-1
2013-01-26 20:06:55 +00:00
Phil Nash 3ce320db4f More console reporter tweaks 2013-01-18 08:09:28 +00:00
Phil Nash b588755a92 Tweaked console reporter some more 2013-01-17 12:07:34 +00:00
Phil Nash 10e891767f Dropped "Test case" and "Section" prefixes in test report headers 2013-01-17 11:47:23 +00:00
Phil Nash 5a60ce2117 console reporter: got rid of spurious blank lines 2013-01-16 09:30:41 +00:00
Phil Nash f8ba2277d3 console reporter:
Always print test case + sections in header for every new section.
Group sections into single block
Tweaked BDD mappings to print out nicely with above
2013-01-15 23:14:52 +00:00
Phil Nash 21c479f5aa More console reporter tweaks and approved new output 2013-01-14 18:36:25 +00:00
Phil Nash 42aef1d99c Fairly major reworking of console reporter (still in progress).
Changed reporter interface a bit.
2013-01-13 21:51:44 +00:00
Phil Nash 619d53439d Added "basic" reports to the Approval results (in addition to the console reports) 2013-01-03 19:19:00 +00:00
Phil Nash bcf722eb81 Reporter interface uses value types instead of shared ptrs again 2013-01-03 09:04:46 +00:00
Phil Nash 7409075302 Approval filter condenses hop filenames as well as cpp 2013-01-03 08:48:05 +00:00
Phil Nash 8b71158540 Fixed reference to basic reporter (to console reporter) 2012-12-14 18:17:47 +00:00
Phil Nash 86ad6348d4 Split original/ expanded expressions over multiple lines 2012-12-14 07:49:18 +00:00
Phil Nash eac51f38bd Fix for long headers 2012-12-13 12:57:49 +00:00
Phil Nash a7079a2dbe Changed header and summary logs to multiline forms 2012-12-13 12:46:47 +00:00
Phil Nash 6488fc1c88 Console reporter: Don't print full path for every line 2012-12-11 09:02:31 +00:00
Phil Nash 6fb8260add Tweaks to summary counts in console reporter 2012-12-11 08:27:21 +00:00
Phil Nash bcad093af7 Console reporter is now the default 2012-12-10 08:54:57 +00:00
Phil Nash f4c0a1848d console reporter is now a full replacement for the basic reporter, using the new streaming interface directly 2012-12-09 21:46:15 +00:00
Phil Nash 51f0572209 Added approval test for aborted test results (-a) 2012-12-09 11:33:54 +00:00
Phil Nash daedf8ff5f Minimal changes to get iTchRunner to work again 2012-12-06 18:39:08 +00:00
Phil Nash 442463473d Updated obj-c bindings for new Matchers and TestCaseInfo changes 2012-12-06 08:41:38 +00:00
Phil Nash fe98123d0b Started new reporter, "console", which will replace "basic" when done.
Introduced Option template as part of this.
2012-12-05 08:40:53 +00:00
Phil Nash 2632dca81d Completed IStreamingInterface abstraction with TestRunInfo and GroupInfo 2012-12-01 23:49:57 +00:00
Phil Nash 602880f5ab Approval filenames are now approvedResults.txt and unapprovedResults.txt (only the former is checked in) 2012-12-01 19:11:06 +00:00