-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from Open-ISP/test-all-configs
Test all configs
- Loading branch information
Showing
6 changed files
with
18 additions
and
15 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import pytest | ||
from isp_workbook_parser import Parser | ||
from pathlib import Path | ||
|
||
workbook_path = Path("workbooks") | ||
|
||
|
||
@pytest.mark.parametrize("workbook_version_folder", workbook_path.iterdir()) | ||
def test_packaged_table_configs_for_each_version(workbook_version_folder: Path): | ||
xl_file = [file for file in workbook_version_folder.glob("*.xls*")] | ||
assert ( | ||
len(xl_file) == 1 | ||
), f"There should only be one Excel workbook in each version sub-directory, got {xl_file}" | ||
workbook_name = xl_file.pop() | ||
workbook = Parser(workbook_name) | ||
configs = workbook.get_table_names() | ||
for config in configs: | ||
workbook.get_table(config, config_checks=True) |
Binary file not shown.
Binary file not shown.