From d56cd2e352eeb25470b1157e87b12e12cde5f5d0 Mon Sep 17 00:00:00 2001 From: DaniRafeh28 <daniel.rafeh@student.reutlingen-university.de> Date: Sat, 5 Apr 2025 13:40:17 +0200 Subject: [PATCH] 2 fails - Report adjusted --- Project_Test/other/WeishauptOrlando/string_calculator.py | 5 ++++- Project_Test/report.md | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Project_Test/other/WeishauptOrlando/string_calculator.py b/Project_Test/other/WeishauptOrlando/string_calculator.py index cf19738..dc89d97 100644 --- a/Project_Test/other/WeishauptOrlando/string_calculator.py +++ b/Project_Test/other/WeishauptOrlando/string_calculator.py @@ -1,5 +1,8 @@ # Implementierung von IStringCalculator from abc import ABC, abstractmethod +import sys +sys.path.append(r'C:\Users\HP\Downloads\ReportingService\ReportingService\Frontend\Neuer Ordner\Neuer Ordner\modern-dev-tdd-assignments') +from Project_Test.stringCalculator import StringCalculator as DaniCalc # Definition des Interfaces für den StringCalculator class IStringCalculator(ABC): @@ -55,7 +58,7 @@ import unittest class TestStringCalculator(unittest.TestCase): def setUp(self): # Vor jedem Test wird eine Instanz des Calculators erstellt - self.calc = StringCalculator() + self.calc = DaniCalc() def test_add_empty_string(self): # Leerer String → 0 diff --git a/Project_Test/report.md b/Project_Test/report.md index 555430e..993167d 100644 --- a/Project_Test/report.md +++ b/Project_Test/report.md @@ -19,5 +19,5 @@ String Calculator - My Code tested with the other students testcases | GotsisWasilios | no | 2 failed testcases ( the test expected a ValueError to be raised but it wasn't - test_add_exception, test_add_negative_numbers) | | PikkemaatLasse | yes (1) | 2 failed testcases ( again ValueError expected - test_add_single_negative_number, test_add_multiple_negative_numbers) | | YildirimHatice | no | 2 failed testcases ( again ValueError expected - test_negative_number, test_multiple_negative_numbers) | -| WeishauptOrlando | | | +| WeishauptOrlando | no | 2 failed testcases (ValueError expected again - test_add_raises_exception_on_negative_number, test_add_raises_exception_on_multiple_negatives) | | SerchimoMarvin | | | \ No newline at end of file -- GitLab