test_main.py 378 B

123456789101112131415161718
  1. import unittest
  2. from utils import run_file
  3. class TestMain(unittest.TestCase):
  4. def test_po_main(self):
  5. self.main("PO")
  6. def test_co_main(self):
  7. self.main("CO")
  8. def main(self, mode):
  9. self.assertTrue(run_file(["main.alc", "primitives.alc"],
  10. [],
  11. ["Hello, world!", "Hello, world!", "Hello, world!"],
  12. mode))