From c154f040841e9a7ec45f6773a83d8af556d961bd Mon Sep 17 00:00:00 2001 From: orchestrator-bot Date: Sun, 16 Aug 2026 18:35:42 +0000 Subject: [PATCH] tester: add unit tests iteration 1 --- __pycache__/test_hello.cpython-313.pyc | Bin 0 -> 1485 bytes test_hello.py | 29 +++++++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 __pycache__/test_hello.cpython-313.pyc create mode 100644 test_hello.py diff --git a/__pycache__/test_hello.cpython-313.pyc b/__pycache__/test_hello.cpython-313.pyc new file mode 100644 index 0000000000000000000000000000000000000000..d314afb284be9735d659f02e54a8430ee3ff4e28 GIT binary patch literal 1485 zcmcgs&1(}u6ras*Hj|jxMruu4ty?`vYE2JXMG-+nP{az|ih_kXxBh1ur16^3^H4v(WZ>psJl;~KU$#A7`CzRG-J*>#t_>+ zG1A3!3!CV$7OQGit(g2s@?<#%(5`iamW9j$n_-~Y3=*~mI>iBots_m^2AI`k(NyVa zH;_l%dfop>sgz@Ta+AV8#n*a{WPzPQ8m*~B%yoCnQ?nD}30udXVJG(*o_3N=#r5d| z*-356{7LMvwmH%9YB97+uYyRS@GvgE8Ity#*e)VOLjpytWI+SX2V z%sS;my)v@RlD-wliXY07N;R&^S>N0FjmJjQ-!kKueYg-boU*&9tF>jPAwzHl;v1n< zhIFq;rI#;PfC8V-{o;HQYnutevkmaeZV)IPLQk!6g1`lN_+sePRR&yi=av16t9Yb1 z>M1h{XfdITz^$KCCb&UZmjNANS*p+tX9 zhr;iV?e z-pk$1-S?kfdU5U9wYPkth3@_`LDB8_e-l(q75V%Q%Kwi^@GBv9#PZs`cLA)ZpCzDi z2aaSKX!?LgO|i+M0c%O@A<|3Vs7GiBeJFGq0~<)u_fwfYUqmo9ylNYM==0=d50ZcD z#FI^rH@!@}<=bHpZ5J`ll;T2o&YUZR$_O!siPnkF3PA(c(ewy$t_Fdu*E|tMKkBr zJRyo^yMl^`UQJSo6sM9La_};=y^RpuAnEn|)3kRi|Bm&1 sG5fT!`+T`~WT|)L3qxV0#Ek5n`PceD)5zXFe&hJf6DvA12HT;12cYazBLDyZ literal 0 HcmV?d00001 diff --git a/test_hello.py b/test_hello.py new file mode 100644 index 0000000..a04d2ce --- /dev/null +++ b/test_hello.py @@ -0,0 +1,29 @@ +import subprocess +import unittest + + +class TestHello(unittest.TestCase): + def test_hello_output(self): + """Test that hello.py prints 'Hello, World!' to stdout.""" + result = subprocess.run( + ["python3", "hello.py"], + capture_output=True, + text=True, + cwd="/workspace" + ) + self.assertEqual(result.returncode, 0) + self.assertIn("Hello, World!", result.stdout) + + def test_hello_no_stderr(self): + """Test that hello.py produces no stderr output.""" + result = subprocess.run( + ["python3", "hello.py"], + capture_output=True, + text=True, + cwd="/workspace" + ) + self.assertEqual(result.stderr, "") + + +if __name__ == "__main__": + unittest.main()