Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sdc50 committed Sep 26, 2023
1 parent 601f5a3 commit 31ef661
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/unit_tests/test_tethys_cli/test_gen_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ def test_generate_command_metayaml(
_,
mock_os_path_join,
):
mock_args = mock.MagicMock()
mock_args = mock.MagicMock(micro=False)
mock_args.type = GEN_META_YAML_OPTION
mock_args.directory = None
mock_args.pin_level = "minor"
Expand All @@ -478,6 +478,7 @@ def test_generate_command_metayaml(

render_context = mock_Template().render.call_args.args[0]
expected_context = {
"package_name": "tethys-platform",
"run_requirements": ["foo=1.2.*", "bar=4.5", "goo=7.8"],
"tethys_version": mock.ANY,
}
Expand All @@ -492,7 +493,7 @@ def test_generate_command_metayaml(
def test_gen_meta_yaml_overriding_dependencies(
self, _, mock_load, mock_dvfce, mock_write_info
):
mock_args = mock.MagicMock()
mock_args = mock.MagicMock(micro=False)
mock_args.type = GEN_META_YAML_OPTION
mock_args.directory = None
mock_args.pin_level = "minor"
Expand All @@ -514,6 +515,7 @@ def test_gen_meta_yaml_overriding_dependencies(
mock_dvfce.assert_called_with("foo", level="minor")

expected_context = {
"package_name": "tethys-platform",
"run_requirements": [
mock_dvfce(),
"foo=1.2.3",
Expand Down

0 comments on commit 31ef661

Please sign in to comment.