Skip to content

MingW32 CHECK and CHECK_EQUAL (false) freeze/crash Tests #65

Closed
@M-griffin

Description

@M-griffin

Hi, having some issues trying to write unit tests for my program.
CodeLite and MingW32-4.8.1 in Windows 7 64 bit.

Generate CodeLite project files with cmake gui for Windows. Everything built cleanly with no errors or issues from latest git clone of repo. Latest (HEAD).

I then created my first unit test and tried CHECK(true); To make sure it's working and i get success;

Basic Code:

#include <UnitTest++.h>

SUITE(Tests)
{
    TEST(TestThisNow)
    {
        CHECK(true);
    }
}

// run all tests
int main(int argc, char **argv)
{
    return UnitTest::RunAllTests();
}
Success: 1 tests passed.
Test time: 0.00 seconds.

Press any key to continue.

I then change CHECK(true); -> CHECK(false);

The program just freezes, doesn't return any failure notices.
I then tried:

   CHECK_EQUALS(10,10);  Works
I then changed it to:
   CHECK_EQUALS(10,20);  Freezes again without listing failures

Wonder if I'm missing something or there are issues in the latest repo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions