Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Oct 27 16:34
    krzysztof-jusiak commented #530
  • Oct 27 16:34
    krzysztof-jusiak closed #530
  • Oct 27 16:34

    krzysztof-jusiak on cpp14

    Add Utah C++ Programmers video (compare)

  • Oct 27 16:22
    LegalizeAdulthood opened #530
  • Oct 26 02:45

    krzysztof-jusiak on master

    [cppcon-2021] (compare)

  • Oct 26 02:32

    krzysztof-jusiak on master

    [cppcon-2021] (compare)

  • Oct 26 02:10

    krzysztof-jusiak on master

    [cppcon-2021] (compare)

  • Oct 26 02:05

    krzysztof-jusiak on master

    [cppcon-2021] (compare)

  • Oct 19 11:56
    Micbetter opened #476
  • Oct 19 07:29

    krzysztof-jusiak on master

    [cppcon-2021] embed (compare)

  • Oct 18 21:56

    krzysztof-jusiak on master

    [cppcon-2021] cleanup (compare)

  • Oct 18 17:38

    krzysztof-jusiak on master

    [cppcon-2021] embed (compare)

  • Oct 18 15:01

    krzysztof-jusiak on master

    [cppcon-2021] embed (compare)

  • Oct 18 14:12

    krzysztof-jusiak on master

    [cppcon-2021] embed (compare)

  • Oct 18 13:48
    WojciechMigda commented #276
  • Oct 07 09:18
    b1ackviking commented #277
  • Oct 04 15:58
    tripleslash edited #528
  • Oct 04 15:12
    tripleslash edited #529
  • Oct 04 15:11
    tripleslash opened #529
  • Oct 04 15:07
    tripleslash opened #528
Clare Macrae
@claremacrae
Hi, In order to add a test for this PR, I'm working on understanding the existing tests in ut.cpp....
boost-experimental/ut#300

How do I make the tests there print out the failing values?
For example, when I change this:

    test_assert(1 == reporter.tests_.pass);
-    test_assert(0 == reporter.tests_.fail);
+    test_assert(42_i == reporter.tests_.fail);
    test_assert(0 == reporter.tests_.skip);

I get this output:

/Users/clare/Documents/develop/Testing/ut-claremacrae/cmake-build-spaces/cmake-build-debug-gcc9-brew/test/ut/ut
/Users/clare/Documents/develop/Testing/ut-claremacrae/test/ut/ut.cpp:393:FAILED

Process finished with exit code 6
I would like it to print out something like 42 != 0
Kris Jusiak
@krzysztof-jusiak

Right, that's a bit of tricky how to test a unit test framework without a unit test framework?

  • One way would be to use UT expect instead of test_assert which is just a poor's man assert, but that would be using testing code to test code, not ideal;
  • Another way would be just to do `std::cerr << reporter.tests_.fail, not great too;
  • Use alternative UT framework for verification, hmm
  • Implement a better test_assert which acts more like expect but that would require tests around it as well
  • Use a debugger to get values on failure with catch throw
  • ...

Not sure what's the best solution here; for me, small changes and line where it failed is usually enough to deal with it but I don't like the experience, that's why [Boost].UT came about in the first place!

Kunal Tyagi
@kunaltyagi
Is UT on conan? I see a conanfile, but no packages match the pattern 'UT'
Kris Jusiak
@krzysztof-jusiak
I don't think so :point_up: not yet
Kris Jusiak
@krzysztof-jusiak