-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(coverage): update to not use path
- Loading branch information
Showing
3 changed files
with
9 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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,10 +1,11 @@ | ||
from subprocess import check_call | ||
from webbrowser import open_new_tab | ||
|
||
from path import Path # requires path | ||
from pathlib import Path # requires path | ||
from os import chdir | ||
|
||
repo = Path(__file__).parent.parent | ||
repo.cd() | ||
chdir(repo) | ||
check_call(['coverage', 'run', '-m', 'pytest']) | ||
check_call(['coverage', 'html']) | ||
open_new_tab(repo / 'htmlcov/index.html') | ||
open_new_tab(f'{repo}/htmlcov/index.html') |
This file contains 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 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