From 29da792d3bbf972d34c329ab7501253a8beff5c6 Mon Sep 17 00:00:00 2001 From: Ari Trachtenberg Date: Sun, 22 Sep 2024 14:08:07 -0400 Subject: [PATCH] fixed lab0p4 testing error --- problems/LabZero_ChapterThree.h | 6 +++--- tests/LabZero.cpp | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/problems/LabZero_ChapterThree.h b/problems/LabZero_ChapterThree.h index 7bc0194..0e0d3f0 100644 --- a/problems/LabZero_ChapterThree.h +++ b/problems/LabZero_ChapterThree.h @@ -17,7 +17,7 @@ void labZero_pThree(); /** - * @input read in four pairs of integral x y coordinates, one per line. + * @input read in four pairs of integral x y coordinates, one per line, in clock-wise order * @output outputs the most specific description of the * four points among the following choices: * square, rectangle, trapezoid, rhombus, none of these @@ -25,15 +25,15 @@ void labZero_pThree(); * @example 1 * 0 0 * 0 1 - * 1 0 * 1 1 + * 1 0 * square * * @example 2 * 0 0 * 0 1 - * 2 0 * 1 1 + * 2 0 * trapezoid */ void labZero_pFour(); diff --git a/tests/LabZero.cpp b/tests/LabZero.cpp index 17ef902..c9f7eef 100644 --- a/tests/LabZero.cpp +++ b/tests/LabZero.cpp @@ -70,14 +70,14 @@ bool test_labZero_pFour() { string out; // example 1 - Common::redirIO("0 0\n0 1\n1 0\n1 1\n"); + Common::redirIO("0 0\n0 1\n1 1\n1 0\n"); labZero_pFour(); out = Common::restoreIO(); if (out.find("square") == string::npos) return false; // example 2 - Common::redirIO("0 0\n0 1\n2 0\n1 1\n"); + Common::redirIO("0 0\n0 1\n1 1\n2 0\n"); labZero_pFour(); out = Common::restoreIO(); if (out.find("trapezoid") == string::npos) -- GitLab