-
Notifications
You must be signed in to change notification settings - Fork 0
Feat/cs 40549 roles class implementation #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
sunil-lakshman
merged 18 commits into
feat/CS-40545-metadata-class-implemetation
from
feat/CS-40549-roles-class-implementation
Aug 23, 2023
Merged
Changes from 10 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
fac7006
Created roles class with unit testcases, mock test cases and api test…
sunil-lakshman 6617121
Updated coverage report github workflow file
sunil-lakshman f2fcf0b
Added coverage install command
sunil-lakshman f400093
Added pytest install command
sunil-lakshman e18a162
Updated stack class unit test file
sunil-lakshman b022d75
Added html coverage
sunil-lakshman 663c9b6
Added coverage reports and visualizations
sunil-lakshman 9315911
Removed visualisation
sunil-lakshman 33dcd7c
Generating coverage report in svg format
sunil-lakshman 9fa117e
Added coverage-badge install command
sunil-lakshman 8f76af2
Fixed PR comments and code optimisation
sunil-lakshman 6089eb2
Added coverage reports graphical visualisation in github page
sunil-lakshman 05ce8d7
Merge branch 'feat/CS-40545-metadata-class-implemetation' into feat/C…
sunil-lakshman 62bb9e3
Created readme file
sunil-lakshman 7aac2d5
changed variable name
sunil-lakshman 8451c11
Updated readme file
sunil-lakshman 603ba2c
Update README.md
ishaileshmishra d61bfd3
Added auditlog class and license file (#17)
sunil-lakshman File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,45 +1,44 @@ | ||
| name: Pytest Workflow | ||
| name: Coverage Report | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| on: [push] # You can adjust the trigger events as needed | ||
|
|
||
| jobs: | ||
| coverage-report: | ||
| strategy: | ||
| matrix: | ||
| python-version: | ||
| - 3.9 | ||
| coverage: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v2 | ||
| - uses: actions/setup-python@v2 | ||
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
| - name: Install build dependencies | ||
| run: pip install --upgrade setuptools | ||
| - name: Install dot env | ||
| run: pip install python-dotenv | ||
| - name: Install requests | ||
| run: pip install requests | ||
| - name: Change to test directory | ||
| run: cd tests/unit | ||
| - uses: lpenz/ghaction-pytest-cov@v1 | ||
| - uses: AndreMiras/coveralls-python-action@v20201129 | ||
| - name: Checkout code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Set up Python | ||
| uses: actions/setup-python@v2 | ||
| with: | ||
| parallel: true | ||
| flag-name: python-${{ matrix.python-version }} | ||
| github-token: ${{ secrets.GITHUB_TOKEN }} | ||
|
|
||
|
|
||
| coverage-finish: | ||
| needs: coverage-report | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: AndreMiras/coveralls-python-action@v20201129 | ||
| python-version: 3.11 # Choose the appropriate Python version | ||
|
|
||
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install -r requirements.txt # If you have a requirements file | ||
| pip install coverage | ||
| pip install pytest | ||
| pip install coverage-badge | ||
|
|
||
|
|
||
| - name: Run tests and coverage | ||
| run: | | ||
| coverage run -m pytest tests/unit/ | ||
| coverage report --include="tests/unit/*" -m > coverage_report.txt | ||
| coverage xml --include="tests/unit/*" -o coverage.xml | ||
| coverage html --include="tests/unit/*" | ||
| coverage-badge -o coverage.svg | ||
|
|
||
| - name: Upload coverage artifact | ||
| uses: actions/upload-artifact@v2 | ||
| with: | ||
| parallel-finished: true | ||
| name: coverage-report | ||
| path: | | ||
| coverage_report.txt | ||
| coverage.xml | ||
| htmlcov | ||
| coverage.svg | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,9 @@ | ||
| class Error(Exception): | ||
|
|
||
| pass | ||
| def __init__(self, f, *args): | ||
| super().__init__(args) | ||
| self.f = f | ||
|
|
||
| def __str__(self): | ||
| return f'The {self.f} uid is required' | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ArgumentException @sunil-lakshman