diff --git a/.github/workflows/ci_cd_wf.yml b/.github/workflows/ci_cd_wf.yml new file mode 100644 index 00000000..29a4a145 --- /dev/null +++ b/.github/workflows/ci_cd_wf.yml @@ -0,0 +1,29 @@ +name: test + +on: + push: + branches: + - main + pull_request: + branches: + - "*" + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - name: Check out repo code + uses: actions/checkout@v3 + + - name: Setup Python + uses: actions/setup-python@v3 + with: + python-version: "3.x" + + - name: Install Dependencies + run: | + python -m pip install -r requirements.txt + - name: Run tests + run: | + python -m pytest -v tests diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 00000000..9ee86e71 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,6 @@ +{ + "[python]": { + "editor.defaultFormatter": "ms-python.autopep8" + }, + "python.formatting.provider": "none" +} \ No newline at end of file diff --git a/tests/test_calculator.py b/tests/test_calculator.py index e69de29b..44117c96 100644 --- a/tests/test_calculator.py +++ b/tests/test_calculator.py @@ -0,0 +1,2 @@ +def test_add(): + assert add(1,1) == 2