Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Test cases added to test_cli to cover new case
  • Loading branch information
ModernMAK committed Oct 15, 2023
1 parent afd036a commit fb8f924
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ packages = find_namespace:
python_requires = >=3.9
install_requires =
relic-tool-sga-core >= 1.1.0
relic-tool-sga-core >= 1.1.1
mak-serialization-tools
fs
Expand Down
2 changes: 1 addition & 1 deletion src/relic/sga/v2/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

from relic.sga.v2.serialization import essence_fs_serializer as EssenceFSHandler

__version__ = "1.1.0"
__version__ = "1.1.1"

__all__ = [
"EssenceFSHandler",
Expand Down
Binary file added tests/data/SampleSGA-v2-Oct-15-2023.sga
Binary file not shown.
10 changes: 6 additions & 4 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import io
import os.path
import subprocess

# Local testing requires running `pip install -e "."`
import tempfile
from contextlib import redirect_stdout
Expand All @@ -11,7 +10,6 @@
import pytest
from fs.base import FS
from fs.info import Info
from fs.walk import Step


class CommandTests:
Expand Down Expand Up @@ -53,8 +51,12 @@ class TestRelicSgaCli(CommandTests):
...


_SAMPLE_V2 = os.path.abspath(os.path.join(__file__, "../data/SampleSGA-v2.sga"))
_SAMPLES = [_SAMPLE_V2]
def _get_sample_file(path:str):
return os.path.abspath(os.path.join(__file__, "../data", path))

_SAMPLE_V2 = _get_sample_file("SampleSGA-v2.sga")
_SAMPLE_V2_OCT_15_2023 = _get_sample_file("SampleSGA-v2-Oct-15-2023.sga")
_SAMPLES = [_SAMPLE_V2, _SAMPLE_V2_OCT_15_2023]


@pytest.mark.parametrize("src", argvalues=_SAMPLES, ids=_SAMPLES)
Expand Down

0 comments on commit fb8f924

Please sign in to comment.