From a6b7ba41eea9fd9130715fe4c774b70af56b79d6 Mon Sep 17 00:00:00 2001 From: Seraphima Zykova Date: Wed, 1 Apr 2020 13:12:29 +0300 Subject: [PATCH] removed tests with unused scenario that slowdown CI (#1820) --- .../tests/UnitTests/FancyZones.Spec.cpp | 82 ------------------- 1 file changed, 82 deletions(-) diff --git a/src/modules/fancyzones/tests/UnitTests/FancyZones.Spec.cpp b/src/modules/fancyzones/tests/UnitTests/FancyZones.Spec.cpp index 091f0e8217..1a7b6a05b6 100644 --- a/src/modules/fancyzones/tests/UnitTests/FancyZones.Spec.cpp +++ b/src/modules/fancyzones/tests/UnitTests/FancyZones.Spec.cpp @@ -46,88 +46,6 @@ namespace FancyZonesUnitTests auto actual = MakeFancyZones(m_hInst, nullptr); Assert::IsNull(actual.get()); } - - TEST_METHOD (Run) - { - auto actual = MakeFancyZones(m_hInst, m_settings); - - std::vector threads; - std::atomic counter = 0; - const int expectedCount = 10; - - auto runFunc = [&]() { - actual->Run(); - counter++; - }; - - for (int i = 0; i < expectedCount; i++) - { - threads.push_back(std::thread(runFunc)); - } - - for (auto& thread : threads) - { - thread.join(); - } - - Assert::AreEqual(expectedCount, counter.load()); - } - - TEST_METHOD (Destroy) - { - auto actual = MakeFancyZones(m_hInst, m_settings); - - std::vector threads; - std::atomic counter = 0; - const int expectedCount = 10; - - auto destroyFunc = [&]() { - actual->Destroy(); - counter++; - }; - - for (int i = 0; i < expectedCount; i++) - { - threads.push_back(std::thread(destroyFunc)); - } - - for (auto& thread : threads) - { - thread.join(); - } - - Assert::AreEqual(expectedCount, counter.load()); - } - - /* - TEST_METHOD(RunDestroy) - { - auto actual = MakeFancyZones(m_hInst, m_settings); - - std::vector threads; - std::atomic counter = 0; - const int expectedCount = 20; - - auto func = [&]() { - auto idHash = std::hash()(std::this_thread::get_id()); - bool run = (idHash % 2 == 0); - run ? actual->Run() : actual->Destroy(); - counter++; - }; - - for (int i = 0; i < expectedCount; i++) - { - threads.push_back(std::thread(func)); - } - - for (auto& thread : threads) - { - thread.join(); - } - - Assert::AreEqual(expectedCount, counter.load()); - } - */ }; TEST_CLASS (FancyZonesIZoneWindowHostUnitTests)