From ae9c5d2d73b5d07cde7aa39581c348e42b795c3d Mon Sep 17 00:00:00 2001 From: "Daniil (FilippovDY)" Date: Sun, 5 May 2024 23:25:27 +0300 Subject: [PATCH] =?UTF-8?q?build:=20=D0=9F=D0=BE=D0=B2=D1=82=D0=BE=D1=80?= =?UTF-8?q?=D0=BD=D1=8B=D0=B5=20=D0=B4=D0=B5=D0=B9=D1=81=D1=82=D0=B2=D0=B8?= =?UTF-8?q?=D1=8F=20=D1=81=20doctest.h?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Lab01.cbp | 1 + doctest.h | 1 + unittest.cbp | 1 + unittest.cpp | 12 ++++++++++++ 4 files changed, 15 insertions(+) diff --git a/Lab01.cbp b/Lab01.cbp index 30cb1a9..5d67df3 100644 --- a/Lab01.cbp +++ b/Lab01.cbp @@ -38,6 +38,7 @@ + diff --git a/doctest.h b/doctest.h index 5c754cd..6f43ce0 100644 --- a/doctest.h +++ b/doctest.h @@ -7104,3 +7104,4 @@ DOCTEST_SUPPRESS_COMMON_WARNINGS_POP #undef NOMINMAX #undef DOCTEST_UNDEF_NOMINMAX #endif // DOCTEST_UNDEF_NOMINMAX + diff --git a/unittest.cbp b/unittest.cbp index d291579..379d0a2 100644 --- a/unittest.cbp +++ b/unittest.cbp @@ -31,6 +31,7 @@ + diff --git a/unittest.cpp b/unittest.cpp index e69de29..a9ba7e5 100644 --- a/unittest.cpp +++ b/unittest.cpp @@ -0,0 +1,12 @@ +#define DOCTEST_CONFIG_NO_MULTITHREADING +#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN +#include "doctest.h" +#include "histogram_internal.h" + +TEST_CASE("distinct positive numbers") { + double min = 0; + double max = 0; + find_minmax({1, 2}, min, max); + CHECK(min == 1); + CHECK(max == 2); +}