Skip to content

Commit

Permalink
Merge pull request #336 from ej2/update-tests
Browse files Browse the repository at this point in the history
Test Improvements
  • Loading branch information
ej2 authored Jan 4, 2024
2 parents 485626e + f50309a commit d67795a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/codecov.yaml

This file was deleted.

4 changes: 4 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,7 @@ jobs:
- name: Test with pytest
run: |
pytest tests/unit
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
8 changes: 8 additions & 0 deletions tests/unit/objects/test_creditmemo.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,14 @@ def test_valid_object_name(self):

self.assertTrue(result)

def test_to_ref(self):
obj = CreditMemo()
obj.Id = 123

ref = obj.to_ref()
self.assertEqual(ref.value, obj.Id)
self.assertEqual(ref.type, "CreditMemo")


class DiscountLineDetailTests(unittest.TestCase):
def test_init(self):
Expand Down

0 comments on commit d67795a

Please sign in to comment.