From b92f42dc9d8c1a484d502dd48ea623bd7eb30078 Mon Sep 17 00:00:00 2001 From: "(PozdiayevaAV)" Date: Mon, 27 Oct 2025 18:24:36 +0300 Subject: [PATCH] code:.gitignore --- unittest.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 unittest.cpp diff --git a/unittest.cpp b/unittest.cpp new file mode 100644 index 0000000..13c8df0 --- /dev/null +++ b/unittest.cpp @@ -0,0 +1,13 @@ +#define DOCTEST_CONFIG_NO_MULTITHREADING +#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN +#include "doctest.h" +#include "histogram_internal.h" +#include "histogram.h" + +TEST_CASE("distinct positive numbers") { + double minN = 0; + double maxN = 0; + find_minmax({1, 2}, minN, maxN); + CHECK(minN == 1); + CHECK(maxN == 2); +}