-
Notifications
You must be signed in to change notification settings - Fork 1
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 #147 from pepkit/dev
Release 0.11.1
- Loading branch information
Showing
9 changed files
with
186 additions
and
9 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
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 +1 @@ | ||
__version__ = "0.11.0" | ||
__version__ = "0.11.1" |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
sqlalchemy>=2.0.0 | ||
logmuse>=0.2.7 | ||
peppy>=0.40.4 | ||
peppy>=0.40.6 | ||
ubiquerg>=0.6.2 | ||
coloredlogs>=15.0.1 | ||
pytest-mock | ||
|
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,49 @@ | ||
from datetime import datetime | ||
|
||
import pytest | ||
|
||
from pepdbagent.models import TarNamespaceModel | ||
|
||
from .utils import PEPDBAgentContextManager | ||
|
||
|
||
@pytest.mark.skipif( | ||
not PEPDBAgentContextManager().db_setup(), | ||
reason="DB is not setup", | ||
) | ||
class TestGeoTar: | ||
""" | ||
Test project methods | ||
""" | ||
|
||
test_namespace = "namespace1" | ||
|
||
tar_info = TarNamespaceModel( | ||
namespace=test_namespace, | ||
submission_date=datetime.now(), | ||
start_period=datetime.now(), | ||
end_period=datetime.now(), | ||
number_of_projects=1, | ||
file_path="blabla/test.tar", | ||
) | ||
|
||
def test_create_meta_tar(self): | ||
with PEPDBAgentContextManager(add_data=True) as agent: | ||
|
||
agent.namespace.upload_tar_info(tar_info=self.tar_info) | ||
|
||
result = agent.namespace.get_tar_info(namespace=self.test_namespace) | ||
|
||
assert result.count == 1 | ||
|
||
def test_delete_meta_tar(self): | ||
with PEPDBAgentContextManager(add_data=True) as agent: | ||
agent.namespace.upload_tar_info(tar_info=self.tar_info) | ||
|
||
result = agent.namespace.get_tar_info(namespace=self.test_namespace) | ||
assert result.count == 1 | ||
|
||
agent.namespace.delete_tar_info() | ||
|
||
result = agent.namespace.get_tar_info(namespace=self.test_namespace) | ||
assert result.count == 0 |