From f4cfe09cc0a4733c8738d7fda9ffc4a9606b7434 Mon Sep 17 00:00:00 2001 From: Lennart Goetze Date: Wed, 7 Feb 2024 18:44:29 +0100 Subject: [PATCH] Unittest: sucheBuchstabe existiert nicht --- build/test/cache/test_WortSpiel.c | 4 ++-- build/test/out/c/test_WortSpiel.o | Bin 8147 -> 8151 bytes build/test/out/test_WortSpiel.out | Bin 121537 -> 121537 bytes build/test/preprocess/files/test_WortSpiel.c | 4 ++-- .../test/results/test_SchereSteinPapier.pass | 2 +- build/test/results/test_WortSpiel.pass | 2 +- build/test/results/test_ageinseconds.pass | 2 +- build/test/results/test_minirechner.pass | 2 +- build/test/results/test_zahlenraten.pass | 2 +- test/test_WortSpiel.c | 6 ++++++ 10 files changed, 15 insertions(+), 9 deletions(-) diff --git a/build/test/cache/test_WortSpiel.c b/build/test/cache/test_WortSpiel.c index c3bd996..16eb314 100644 --- a/build/test/cache/test_WortSpiel.c +++ b/build/test/cache/test_WortSpiel.c @@ -178,9 +178,9 @@ void testSucheBuchstabe_existiert(void) { char wort1[] = "Programming"; - int index1 = sucheBuchstabe(wort1, 'g'); + int position = sucheBuchstabe(wort1, 'g'); - UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((index1)), ( + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((position)), ( ((void *)0) diff --git a/build/test/out/c/test_WortSpiel.o b/build/test/out/c/test_WortSpiel.o index aed055443a0b91d8c1b24fd031165e990ce355b6..2ceea084b94c8ca6979adf2707fbc64254913900 100644 GIT binary patch delta 611 zcmca?f8CxlrHzjP1P)B(RAziJQFlJ$n~7)LIZZhj7}l^cFoaB&WmIN-IN6a=oz+Bu zfgx#fE~7GQ3XoMcc`8sQZ}LM%k;!Kng&8}6EOo|tlR25xS>FjUFkIMd%2dw6Xt;ST zTLUwr$Ywn*en!h9EDQ{+AnQCqET)MGYz6tnnI)O|c?@2h%Youd6LUm)fHb3*2#5=0 zvPS~xE0asOZKS1vTG`6;i%N_coVh?8ripnFdF{!kxveB}fkLc6M>E)hSWFZ1A(FL| zWqE8Q4uT|sat!7m7SqHmh~&k|g*1p zi-8?#gbIkoG%=YiF|R5yBgc?I73O$|p#qaP@Y?f50Tn@=E6b5P`7f_0_d1XXAQy^j zP7dUA;rR7FX9l#c3&I4l76MriV{XF5 aKETB|fawKdw9@8KiFjs4)6H9@FgTFr3+J%2dw6sK0qF zTLUwr&}Ka@en#^{EDQ{+AnQCqET)MGY?*l}sTGC{UYyH;qD&KWM0tQTqn8kf3uLlK z0_jVW%eZZ%C4m~*%JYj#j2WD{Kpdutc@TNc$!EE(B(i}*tUxC-*n(J06Z0XG)sy9U zY?SwdB!O}a<{%c+#4L#9c_4=)4JgdYz%tohPINN29QWjTJi^@SK!d=B8K_U*!z0IN zKKV9}5BFS{sFwOK0ENI-i-R1&G%*{jMRRfspD@pFkQ~TD!GCO<7xV36 z0tRfHUbC&HR2eAA&F~4x;s>%A8Qg)&A*?tc3nDukF186S_7N_|0kjpO zE*;2%=&gf`oq&tohl?2kT?JHU2DGjN!UVGB16dGbuEWLN!Nu5s=?h}C!sbYccxFc9 J%{!&#SO6)oaWwz{ diff --git a/build/test/out/test_WortSpiel.out b/build/test/out/test_WortSpiel.out index f4eb6c9c08e215f3b2608c602438495f00f6afca..629b3b8789198309569c030f90dec513165caf02 100644 GIT binary patch delta 484 zcmX@OmHpsW_6Z$K1qUW}`7xz3Y`is%iShI1LgugY7#~eeU!>3YVe)h!Id$@JASp5V z`yzc-2RjA^j>(BES2rzL%f@K9dEKf8W=4_C`s?@^U5>CYFt9QJfhUN?G%~o z^NUK18JxL59HxnR5cS%V&#bqS$OQ_qvH^A3f>=xw^C6P8ljSzpC?5n#0_7OYK`f?; zSrEyKKn~a@RtA>I0jUa;=WY<@)&v>?HpoD8^6m|CjFyvcZSdiq4-?hWoNTx;OpAdX zYN85=#WXRQEitbuF(b#2K^5jVh#dlxH*U1&ivlWwx?Yweck;iDp2F)uCV(6)4ziJH zVm8RP+Zi<`H*FH(`3o~%kb!;kqD?XOn?Bv;1qSTB|644XOgW}ch+`C)E)dVivVDyu x<2N?ON81-WFt#%>e%P+<%qY&xICZlZoD;(iSgs+LgugY7#~bdU!>3YZt`>>IeGGNASpKa z`yzc-J39sjj>(BES2rzL%f_g`dEKf8W=5gS`s?@^%@46KFt9QJfhUN?G%b2(6yX=08j50GZ`5(067O!i11eQ9#}dK+m;phmXx{Gt+L24^l1hiPISL|$|9 zx%E~O*+3yyHlT7_5Q}MIK18y5vcd)%<^3Q@pd5oah{ZH93nF3bQh>Ob$p@ zm^^=jFt<9;5U@c8>XY|wkYhBTd}o6X_gt8$milDljbWz$KzxviDj*iq#ALR_ysE^E z976_Gm|q}v@UcVf;9y{x?zkNoN(WYOPrkoVm@fh-1ND(CNA{#mp2BN@B4DeKhp{O{v^USQDP`@hAK$(UpMgg8c#=>qYLEZf&u zGJa#@f56AUzzbB*%*dz8z;J(hpc|v;_G1o=DNKy-wre{xiZe4#-tO$ixK@HuZ2QMJ Q#_x=bcH3VjFy5#H0FPFJ;s5{u diff --git a/build/test/preprocess/files/test_WortSpiel.c b/build/test/preprocess/files/test_WortSpiel.c index c3bd996..16eb314 100644 --- a/build/test/preprocess/files/test_WortSpiel.c +++ b/build/test/preprocess/files/test_WortSpiel.c @@ -178,9 +178,9 @@ void testSucheBuchstabe_existiert(void) { char wort1[] = "Programming"; - int index1 = sucheBuchstabe(wort1, 'g'); + int position = sucheBuchstabe(wort1, 'g'); - UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((index1)), ( + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((position)), ( ((void *)0) diff --git a/build/test/results/test_SchereSteinPapier.pass b/build/test/results/test_SchereSteinPapier.pass index b503cec..d262ba8 100644 --- a/build/test/results/test_SchereSteinPapier.pass +++ b/build/test/results/test_SchereSteinPapier.pass @@ -19,4 +19,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.04560680000031425 +:time: 0.04479449999962526 diff --git a/build/test/results/test_WortSpiel.pass b/build/test/results/test_WortSpiel.pass index 1e8c97e..0291e43 100644 --- a/build/test/results/test_WortSpiel.pass +++ b/build/test/results/test_WortSpiel.pass @@ -51,4 +51,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.856331400000272 +:time: 0.041727399999217596 diff --git a/build/test/results/test_ageinseconds.pass b/build/test/results/test_ageinseconds.pass index 517def0..102ad12 100644 --- a/build/test/results/test_ageinseconds.pass +++ b/build/test/results/test_ageinseconds.pass @@ -23,4 +23,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.04383059999963734 +:time: 0.04086199999983364 diff --git a/build/test/results/test_minirechner.pass b/build/test/results/test_minirechner.pass index 67b0f74..63c9494 100644 --- a/build/test/results/test_minirechner.pass +++ b/build/test/results/test_minirechner.pass @@ -83,4 +83,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.04288310000083584 +:time: 0.04104339999867079 diff --git a/build/test/results/test_zahlenraten.pass b/build/test/results/test_zahlenraten.pass index 4c2841f..2cce87f 100644 --- a/build/test/results/test_zahlenraten.pass +++ b/build/test/results/test_zahlenraten.pass @@ -15,4 +15,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.042165499999100575 +:time: 0.04154709999966144 diff --git a/test/test_WortSpiel.c b/test/test_WortSpiel.c index 4385251..af14f41 100644 --- a/test/test_WortSpiel.c +++ b/test/test_WortSpiel.c @@ -76,6 +76,12 @@ void testSucheBuchstabe_existiert(void) { } +void testSucheBuchstabe_existiertnicht(void) { + char wort2[] = "Testing"; + int position = sucheBuchstabe(wort2, 'z'); + TEST_ASSERT_EQUAL_INT(-1, position); +} + #endif // TEST