diff --git a/lab34/histogram_internal.h b/lab34/histogram_internal.h deleted file mode 100644 index bbe5577..0000000 --- a/lab34/histogram_internal.h +++ /dev/null @@ -1,5 +0,0 @@ -#pragma once -#include - -void -find_minmax(const std::vector& numbers, double& min, double& max, bool& res); diff --git a/lab34/unittest.cbp b/lab34/unittest.cbp deleted file mode 100644 index bffa065..0000000 --- a/lab34/unittest.cbp +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - diff --git a/lab34/unittest.cpp b/lab34/unittest.cpp deleted file mode 100644 index 6f2588a..0000000 --- a/lab34/unittest.cpp +++ /dev/null @@ -1,48 +0,0 @@ -#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; - bool res = true; - find_minmax({1, 2}, min, max ,res); - CHECK(res == true); - CHECK(min == 1); - CHECK(max == 2); -} -TEST_CASE("only one number") { - double min = 0; - double max = 0; - bool res = true; - find_minmax({1}, min, max, res); - CHECK(res == true); - CHECK(min == 1); - CHECK(max == 1); -} -TEST_CASE("distinct negative elements") { - double min = 0; - double max = 0; - bool res = true; - find_minmax({-1, -5}, min, max, res); - CHECK(res == true); - CHECK(min == -5); - CHECK(max == -1); -} -TEST_CASE("equal numbers") { - double min = 0; - double max = 0; - bool res = true; - find_minmax({4, 4, 4}, min, max, res); - CHECK(res == true); - CHECK(min == 4); - CHECK(max == 4); -} -TEST_CASE("no elements in vector") { - double min = 0; - double max = 0; - bool res = true; - find_minmax({}, min, max, res); - CHECK(res == false); -}