Skip to content

Commit

Permalink
Minor fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
vyasr committed Feb 21, 2022
1 parent 4f98865 commit 5f61c44
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions signac/contrib/job.py
Original file line number Diff line number Diff line change
Expand Up @@ -362,6 +362,11 @@ def _statepoint_filename(self):
# TODO: Why is ws a property while workspace is a method? Why don't the
# Project methods for workspace/root_directory also behave the same? We
# should standardize this.
# TODO: The discrepancy between Project and Job in what is defined as a
# "workspace" is also slightly confusing. In view of moving towards a
# unified 3.0 API where both are subclasses of a common Directory or
# similar, we should aim to unify these APIs (although probably with an
# extremely long deprecation period like the entire lifetime of signac 2.0)
@property
def ws(self):
"""Alias for :meth:`~Job.workspace`."""
Expand Down
2 changes: 1 addition & 1 deletion tests/test_synced_collections/test_json_collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class TestJSONDict(JSONCollectionTest, SyncedDictTest):
# See issue: https://github.com/glotzerlab/signac/issues/316.
def test_keys_non_str_valid_type(self, synced_collection, testdata):
for key in (0, None, True):
with pytest.warns(FutureWarning, match="Use of.+as key is deprecated"):
with pytest.deprecated_call(match="Use of.+as key is deprecated"):
synced_collection[key] = testdata
assert str(key) in synced_collection
assert synced_collection[str(key)] == testdata
Expand Down

0 comments on commit 5f61c44

Please sign in to comment.