diff --git a/Python/src/main/com/github/vitalliuss/helloci/app.py b/Python/src/main/com/github/vitalliuss/helloci/app.py new file mode 100644 index 0000000..045f549 --- /dev/null +++ b/Python/src/main/com/github/vitalliuss/helloci/app.py @@ -0,0 +1,12 @@ +# Hello CI! + +def main(): + print("Hello CI!") + + +def do_nothing(): + # do nothing + pass + +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/Python/src/main/com/github/vitalliuss/helloci/empty_class.py b/Python/src/main/com/github/vitalliuss/helloci/empty_class.py new file mode 100644 index 0000000..7659a48 --- /dev/null +++ b/Python/src/main/com/github/vitalliuss/helloci/empty_class.py @@ -0,0 +1,13 @@ +# Empty class for Cobertura code coverage + +class EmptyClass: + + @staticmethod + def empty_method(): + # empty + pass + + @staticmethod + def unused_method(): + # do not use it + pass \ No newline at end of file diff --git a/Python/src/test/com/github/vitalliuss/helloci/app_test.py b/Python/src/test/com/github/vitalliuss/helloci/app_test.py new file mode 100644 index 0000000..c42a69d --- /dev/null +++ b/Python/src/test/com/github/vitalliuss/helloci/app_test.py @@ -0,0 +1,24 @@ +import unittest +from app import App +from empty_class import EmptyClass + +class AppTest(unittest.TestCase): + + def test_should_be_passed(self): + self.assertTrue(True) + + def test_should_be_failed(self): + self.assertTrue(False) + + @unittest.skip("Not implemented yet") + def test_should_be_skipped(self): + self.assertTrue(True) + + def test_another_method(self): + App.do_nothing() + + def test_another_class(self): + EmptyClass.empty_method() + +if __name__ == '__main__': + unittest.main() \ No newline at end of file