Skip to content

Tags: zerodaycode/Zero

Tags

v0.1.0

Toggle v0.1.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Test Suite (#22)

* Zero - test_suite - Very initial implementation of a own test suite, to stop to depend on third party implementations due to our constraints of use the latest C++ features.

Initially, we have:
- Test Suite -> Common structure for handle related test cases
- Test Case  -> A particular user-defined code that will be the testing object
- Test Results -> Structure for hold the results of different suites and the free test cases (There's still a very initial implementation, warnings are not handled by them)
- Assertions -> Only implemented `assertEquals`. We are in a very initial state, so it's fine to test our development workflow right now

Color features: Added some different colors to the terminal output, related by action. This should be completly refactored into their own feature, but due to the incoming std::print and std::format (that won't be usable until LLVM's 17 version, I don't know how to exactly proceed, because printing coloured strings could be done with the planned custom string implementation that we have planned, or just concatenating the color ANSI codes... hard to tell now. But we can think in such a feature in different ways

* Zero - test_suite - Adding correctly the user instanciated suites to the tracker. Declaring the suite library to the rest of the zork.conf(s)

* Zero - test_suite - Top level containers that holds free tests and test suites now stores pointers to the targets, and we are able to avoid with this change the `arithmetic on a pointer to an incomplete type`, letting them on the top-level of the module. This will be useful when we split the components into their module partitions

* Zero - test_suite - Applying the `pass by value - move` idiom to the TestSuite and TestCase defined constructors

* Zero - test_suite
1. Assertions have now their own module
2. Deleted the default constructor for the test suites. A identifier must be generated always by the user

* Zero - test_suite
1. The suite results are now a member of the `Test Suite` type
2. More format and colours
3. Reorganized the Zork's configuration files

* Zero - test_suite
1. Generated a README.md for the `test-suite`
2. `assertNotEquals` standalone functions created