From fdd19095eff1e3c14798d60e746b09d9951a2f14 Mon Sep 17 00:00:00 2001
From: Hong-Phuc Bui <hong-phuc.bui@htwsaar.de>
Date: Mon, 19 May 2025 08:16:49 +0200
Subject: [PATCH] vorlesung
---
ub-3/tictactoe_test.py | 17 ++++++++++++++---
1 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/ub-3/tictactoe_test.py b/ub-3/tictactoe_test.py
index bb9825d..3971c02 100644
--- a/ub-3/tictactoe_test.py
+++ b/ub-3/tictactoe_test.py
@@ -1,7 +1,7 @@
from tictactoe import pruefe_combination, has_spieler_gewonnen, PL1, PL2, EMPTY
-def test_pruefe_combination_horizontal():
+def test_pruefe_combination_horizontal_hvd():
test_board = [
[PL1, PL1, PL1],
[EMPTY, PL2, EMPTY],
@@ -12,7 +12,7 @@
assert result
-def test_pruefe_combination_vertikal():
+def test_pruefe_combination_vertikal_hvd():
test_board = [
[PL1, EMPTY, EMPTY],
[PL1, PL2, EMPTY],
@@ -23,7 +23,7 @@
assert result
-def test_pruefe_combination_diagonal():
+def test_pruefe_combination_diagonal_hvd():
test_board = [
[PL1, EMPTY, EMPTY],
[PL2, PL1, EMPTY],
@@ -32,3 +32,14 @@
result = pruefe_combination( (0,0,"hvd"), test_board )
assert result
+
+
+def test_pruefe_combination_horizontal_h():
+ test_board = [
+ [PL1, EMPTY, EMPTY],
+ [PL1, PL1, PL1],
+ [PL2, PL1, PL1]
+ ]
+
+ result = pruefe_combination( (1,0,"h"), test_board )
+ assert result
--
Gitblit v1.10.0