pyBiocFileCache 0.2.2__tar.gz → 0.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/.github/workflows/pypi-publish.yml +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/.github/workflows/pypi-test.yml +8 -3
- pybiocfilecache-0.3.0/.pre-commit-config.yaml +52 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/AUTHORS.md +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/CHANGELOG.md +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/PKG-INFO +12 -3
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/README.md +5 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/authors.md +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/changelog.md +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/readme.md +5 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/requirements.txt +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/pyproject.toml +15 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/setup.cfg +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/setup.py +5 -6
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/PKG-INFO +12 -3
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/SOURCES.txt +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/requires.txt +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/BiocFileCache.py +10 -8
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/db/Base.py +1 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/db/schema.py +0 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/utils.py +2 -2
- pybiocfilecache-0.3.0/tests/conftest.py +9 -0
- pybiocfilecache-0.3.0/tests/data/test1.txt +1 -0
- pybiocfilecache-0.3.0/tests/data/test2.txt +1 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/tests/test_cache.py +8 -9
- pyBiocFileCache-0.2.2/temp.txt +0 -0
- pyBiocFileCache-0.2.2/tests/conftest.py +0 -10
- pyBiocFileCache-0.2.2/tests/data/test1.txt +0 -1
- pyBiocFileCache-0.2.2/tests/data/test2.txt +0 -1
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/.coveragerc +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/.gitignore +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/.readthedocs.yml +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/CONTRIBUTING.rst +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/LICENSE.txt +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/Makefile +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/_static/.gitignore +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/conf.py +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/contributing.rst +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/index.md +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/docs/license.rst +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/dependency_links.txt +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/not-zip-safe +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/top_level.txt +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/__init__.py +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/_exceptions.py +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pybiocfilecache/db/__init__.py +0 -0
- {pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/tox.ini +0 -0
|
@@ -13,13 +13,18 @@ jobs:
|
|
|
13
13
|
build:
|
|
14
14
|
|
|
15
15
|
runs-on: ubuntu-latest
|
|
16
|
+
strategy:
|
|
17
|
+
matrix:
|
|
18
|
+
python-version: [ '3.8', '3.9', '3.10', '3.11', '3.12' ]
|
|
16
19
|
|
|
20
|
+
name: Python ${{ matrix.python-version }}
|
|
17
21
|
steps:
|
|
18
22
|
- uses: actions/checkout@v2
|
|
19
|
-
- name:
|
|
23
|
+
- name: Setup Python
|
|
20
24
|
uses: actions/setup-python@v2
|
|
21
25
|
with:
|
|
22
|
-
python-version:
|
|
26
|
+
python-version: ${{ matrix.python-version }}
|
|
27
|
+
cache: 'pip'
|
|
23
28
|
- name: Install dependencies
|
|
24
29
|
run: |
|
|
25
30
|
python -m pip install --upgrade pip
|
|
@@ -32,4 +37,4 @@ jobs:
|
|
|
32
37
|
# # flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
|
|
33
38
|
- name: Test with tox
|
|
34
39
|
run: |
|
|
35
|
-
tox
|
|
40
|
+
tox
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
exclude: '^docs/conf.py'
|
|
2
|
+
|
|
3
|
+
repos:
|
|
4
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
5
|
+
rev: v4.6.0
|
|
6
|
+
hooks:
|
|
7
|
+
- id: trailing-whitespace
|
|
8
|
+
- id: check-added-large-files
|
|
9
|
+
- id: check-ast
|
|
10
|
+
- id: check-json
|
|
11
|
+
- id: check-merge-conflict
|
|
12
|
+
- id: check-xml
|
|
13
|
+
- id: check-yaml
|
|
14
|
+
- id: debug-statements
|
|
15
|
+
- id: end-of-file-fixer
|
|
16
|
+
- id: requirements-txt-fixer
|
|
17
|
+
- id: mixed-line-ending
|
|
18
|
+
args: ['--fix=auto'] # replace 'auto' with 'lf' to enforce Linux/Mac line endings or 'crlf' for Windows
|
|
19
|
+
|
|
20
|
+
- repo: https://github.com/PyCQA/docformatter
|
|
21
|
+
rev: v1.7.5
|
|
22
|
+
hooks:
|
|
23
|
+
- id: docformatter
|
|
24
|
+
additional_dependencies: [tomli]
|
|
25
|
+
args: [--in-place, --wrap-descriptions=120, --wrap-summaries=120]
|
|
26
|
+
# --config, ./pyproject.toml
|
|
27
|
+
|
|
28
|
+
- repo: https://github.com/psf/black
|
|
29
|
+
rev: 24.4.0
|
|
30
|
+
hooks:
|
|
31
|
+
- id: black
|
|
32
|
+
language_version: python3
|
|
33
|
+
|
|
34
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
35
|
+
# Ruff version.
|
|
36
|
+
rev: v0.3.7
|
|
37
|
+
hooks:
|
|
38
|
+
- id: ruff
|
|
39
|
+
args: [--fix, --exit-non-zero-on-fix]
|
|
40
|
+
|
|
41
|
+
## If like to embrace black styles even in the docs:
|
|
42
|
+
# - repo: https://github.com/asottile/blacken-docs
|
|
43
|
+
# rev: v1.13.0
|
|
44
|
+
# hooks:
|
|
45
|
+
# - id: blacken-docs
|
|
46
|
+
# additional_dependencies: [black]
|
|
47
|
+
|
|
48
|
+
## Check for misspells in documentation files:
|
|
49
|
+
# - repo: https://github.com/codespell-project/codespell
|
|
50
|
+
# rev: v2.2.5
|
|
51
|
+
# hooks:
|
|
52
|
+
# - id: codespell
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pyBiocFileCache
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: File based cache for resources and metadata
|
|
5
5
|
Home-page: https://github.com/epiviz/pyBiocFileCache
|
|
6
6
|
Author: jkanche
|
|
@@ -11,9 +11,18 @@ Platform: any
|
|
|
11
11
|
Classifier: Development Status :: 4 - Beta
|
|
12
12
|
Classifier: Programming Language :: Python
|
|
13
13
|
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
14
|
-
Provides-Extra: testing
|
|
15
14
|
License-File: LICENSE.txt
|
|
16
15
|
License-File: AUTHORS.md
|
|
16
|
+
Requires-Dist: importlib-metadata; python_version < "3.8"
|
|
17
|
+
Requires-Dist: sqlalchemy<2.1,>=2
|
|
18
|
+
Provides-Extra: testing
|
|
19
|
+
Requires-Dist: setuptools; extra == "testing"
|
|
20
|
+
Requires-Dist: pytest; extra == "testing"
|
|
21
|
+
Requires-Dist: pytest-cov; extra == "testing"
|
|
22
|
+
|
|
23
|
+
[](https://pyscaffold.org/)
|
|
24
|
+
[](https://pypi.org/project/pyBiocFileCache/)
|
|
25
|
+

|
|
17
26
|
|
|
18
27
|
# pyBiocFileCache
|
|
19
28
|
|
|
@@ -29,7 +38,7 @@ Package is published to [PyPI](https://pypi.org/project/pyBiocFileCache/)
|
|
|
29
38
|
pip install pybiocfilecache
|
|
30
39
|
```
|
|
31
40
|
|
|
32
|
-
#### Initialize a cache directory
|
|
41
|
+
#### Initialize a cache directory
|
|
33
42
|
|
|
34
43
|
```
|
|
35
44
|
from pybiocfilecache import BiocFileCache
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
[](https://pyscaffold.org/)
|
|
2
|
+
[](https://pypi.org/project/pyBiocFileCache/)
|
|
3
|
+

|
|
4
|
+
|
|
1
5
|
# pyBiocFileCache
|
|
2
6
|
|
|
3
7
|
File system based cache for resources & metadata. Compatible with [BiocFileCache R package](https://github.com/Bioconductor/BiocFileCache)
|
|
@@ -12,7 +16,7 @@ Package is published to [PyPI](https://pypi.org/project/pyBiocFileCache/)
|
|
|
12
16
|
pip install pybiocfilecache
|
|
13
17
|
```
|
|
14
18
|
|
|
15
|
-
#### Initialize a cache directory
|
|
19
|
+
#### Initialize a cache directory
|
|
16
20
|
|
|
17
21
|
```
|
|
18
22
|
from pybiocfilecache import BiocFileCache
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
[](https://pyscaffold.org/)
|
|
2
|
+
[](https://pypi.org/project/pyBiocFileCache/)
|
|
3
|
+

|
|
4
|
+
|
|
1
5
|
# pyBiocFileCache
|
|
2
6
|
|
|
3
7
|
File system based cache for resources & metadata. Compatible with [BiocFileCache R package](https://github.com/Bioconductor/BiocFileCache)
|
|
@@ -12,7 +16,7 @@ Package is published to [PyPI](https://pypi.org/project/pyBiocFileCache/)
|
|
|
12
16
|
pip install pybiocfilecache
|
|
13
17
|
```
|
|
14
18
|
|
|
15
|
-
#### Initialize a cache directory
|
|
19
|
+
#### Initialize a cache directory
|
|
16
20
|
|
|
17
21
|
```
|
|
18
22
|
from pybiocfilecache import BiocFileCache
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
furo
|
|
1
2
|
# Requirements file for ReadTheDocs, check .readthedocs.yml.
|
|
2
3
|
# To build the module reference correctly, make sure every external package
|
|
3
4
|
# under `install_requires` in `setup.cfg` is also listed here!
|
|
4
5
|
# sphinx_rtd_theme
|
|
5
6
|
recommonmark
|
|
6
7
|
sphinx>=3.2.1
|
|
7
|
-
furo
|
|
@@ -6,3 +6,18 @@ build-backend = "setuptools.build_meta"
|
|
|
6
6
|
[tool.setuptools_scm]
|
|
7
7
|
# See configuration details in https://github.com/pypa/setuptools_scm
|
|
8
8
|
version_scheme = "no-guess-dev"
|
|
9
|
+
|
|
10
|
+
[tool.ruff]
|
|
11
|
+
line-length = 120
|
|
12
|
+
src = ["src"]
|
|
13
|
+
exclude = ["tests"]
|
|
14
|
+
extend-ignore = ["F821"]
|
|
15
|
+
|
|
16
|
+
[tool.ruff.pydocstyle]
|
|
17
|
+
convention = "google"
|
|
18
|
+
|
|
19
|
+
[tool.ruff.per-file-ignores]
|
|
20
|
+
"__init__.py" = ["E402", "F401"]
|
|
21
|
+
|
|
22
|
+
[tool.black]
|
|
23
|
+
force-exclude = "__init__.py"
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
"""
|
|
2
|
-
Setup file for pyBiocFileCache.
|
|
3
|
-
Use setup.cfg to configure your project.
|
|
1
|
+
"""Setup file for pyBiocFileCache. Use setup.cfg to configure your project.
|
|
4
2
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
This file was generated with PyScaffold 4.1.
|
|
4
|
+
PyScaffold helps you to put up the scaffold of your new Python project.
|
|
5
|
+
Learn more under: https://pyscaffold.org/
|
|
8
6
|
"""
|
|
7
|
+
|
|
9
8
|
from setuptools import setup
|
|
10
9
|
|
|
11
10
|
if __name__ == "__main__":
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pyBiocFileCache
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: File based cache for resources and metadata
|
|
5
5
|
Home-page: https://github.com/epiviz/pyBiocFileCache
|
|
6
6
|
Author: jkanche
|
|
@@ -11,9 +11,18 @@ Platform: any
|
|
|
11
11
|
Classifier: Development Status :: 4 - Beta
|
|
12
12
|
Classifier: Programming Language :: Python
|
|
13
13
|
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
14
|
-
Provides-Extra: testing
|
|
15
14
|
License-File: LICENSE.txt
|
|
16
15
|
License-File: AUTHORS.md
|
|
16
|
+
Requires-Dist: importlib-metadata; python_version < "3.8"
|
|
17
|
+
Requires-Dist: sqlalchemy<2.1,>=2
|
|
18
|
+
Provides-Extra: testing
|
|
19
|
+
Requires-Dist: setuptools; extra == "testing"
|
|
20
|
+
Requires-Dist: pytest; extra == "testing"
|
|
21
|
+
Requires-Dist: pytest-cov; extra == "testing"
|
|
22
|
+
|
|
23
|
+
[](https://pyscaffold.org/)
|
|
24
|
+
[](https://pypi.org/project/pyBiocFileCache/)
|
|
25
|
+

|
|
17
26
|
|
|
18
27
|
# pyBiocFileCache
|
|
19
28
|
|
|
@@ -29,7 +38,7 @@ Package is published to [PyPI](https://pypi.org/project/pyBiocFileCache/)
|
|
|
29
38
|
pip install pybiocfilecache
|
|
30
39
|
```
|
|
31
40
|
|
|
32
|
-
#### Initialize a cache directory
|
|
41
|
+
#### Initialize a cache directory
|
|
33
42
|
|
|
34
43
|
```
|
|
35
44
|
from pybiocfilecache import BiocFileCache
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
.coveragerc
|
|
2
2
|
.gitignore
|
|
3
|
+
.pre-commit-config.yaml
|
|
3
4
|
.readthedocs.yml
|
|
4
5
|
AUTHORS.md
|
|
5
6
|
CHANGELOG.md
|
|
@@ -9,7 +10,6 @@ README.md
|
|
|
9
10
|
pyproject.toml
|
|
10
11
|
setup.cfg
|
|
11
12
|
setup.py
|
|
12
|
-
temp.txt
|
|
13
13
|
tox.ini
|
|
14
14
|
.github/workflows/pypi-publish.yml
|
|
15
15
|
.github/workflows/pypi-test.yml
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
"""
|
|
2
|
-
Python Implementation of BiocFileCache
|
|
3
|
-
"""
|
|
1
|
+
"""Python Implementation of BiocFileCache."""
|
|
4
2
|
|
|
5
3
|
import os
|
|
6
4
|
from pathlib import Path
|
|
@@ -21,9 +19,7 @@ __license__ = "MIT"
|
|
|
21
19
|
|
|
22
20
|
|
|
23
21
|
class BiocFileCache:
|
|
24
|
-
"""
|
|
25
|
-
Class to manage and cache files.
|
|
26
|
-
"""
|
|
22
|
+
"""Class to manage and cache files."""
|
|
27
23
|
|
|
28
24
|
def __init__(self, cacheDirOrPath: Union[str, Path] = create_tmp_dir()):
|
|
29
25
|
"""Initialize BiocFileCache.
|
|
@@ -90,7 +86,13 @@ class BiocFileCache:
|
|
|
90
86
|
|
|
91
87
|
# create new record in the database
|
|
92
88
|
res = Resource(
|
|
93
|
-
**dict(
|
|
89
|
+
**dict(
|
|
90
|
+
rid=rid,
|
|
91
|
+
rname=rname,
|
|
92
|
+
rpath=rpath,
|
|
93
|
+
rtype=rtype,
|
|
94
|
+
fpath=str(fpath),
|
|
95
|
+
)
|
|
94
96
|
)
|
|
95
97
|
|
|
96
98
|
# If this was higher up a parallel process could have added the key to
|
|
@@ -164,7 +166,7 @@ class BiocFileCache:
|
|
|
164
166
|
return resource
|
|
165
167
|
|
|
166
168
|
def get(self, rname: str) -> Optional[Resource]:
|
|
167
|
-
"""
|
|
169
|
+
"""Get resource by name from cache.
|
|
168
170
|
|
|
169
171
|
Args:
|
|
170
172
|
rname (str): Name of the file to search.
|
|
@@ -13,7 +13,7 @@ Base = declarative_base()
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
def create_schema(cache_dir: str) -> Tuple[Engine, sessionmaker]:
|
|
16
|
-
"""Create the schema in the sqlite database
|
|
16
|
+
"""Create the schema in the sqlite database.
|
|
17
17
|
|
|
18
18
|
Args:
|
|
19
19
|
cache_dir (str): Location where the cache directory
|
|
@@ -9,7 +9,7 @@ import sys
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
def create_tmp_dir() -> str:
|
|
12
|
-
"""
|
|
12
|
+
"""Create a temporary directory.
|
|
13
13
|
|
|
14
14
|
Returns:
|
|
15
15
|
str: path to the directory
|
|
@@ -57,7 +57,7 @@ def copy_or_move(
|
|
|
57
57
|
|
|
58
58
|
|
|
59
59
|
def setup_logging(loglevel):
|
|
60
|
-
"""Setup basic logging
|
|
60
|
+
"""Setup basic logging.
|
|
61
61
|
|
|
62
62
|
Args:
|
|
63
63
|
loglevel (int): minimum loglevel for emitting messages
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""Dummy conftest.py for pybiocfilecache.
|
|
2
|
+
|
|
3
|
+
If you don't know what this is for, just leave it empty.
|
|
4
|
+
Read more about conftest.py under:
|
|
5
|
+
- https://docs.pytest.org/en/stable/fixture.html
|
|
6
|
+
- https://docs.pytest.org/en/stable/writing_plugins.html
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
# import pytest
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
test1
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
test2
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import os
|
|
2
|
-
import shutil
|
|
3
2
|
|
|
4
3
|
from pybiocfilecache.BiocFileCache import BiocFileCache
|
|
5
4
|
|
|
@@ -12,7 +11,7 @@ CACHE_DIR = os.getcwd() + "/cache"
|
|
|
12
11
|
|
|
13
12
|
def test_create_cache():
|
|
14
13
|
bfc = BiocFileCache(CACHE_DIR)
|
|
15
|
-
assert os.path.exists(CACHE_DIR
|
|
14
|
+
assert os.path.exists(CACHE_DIR)
|
|
16
15
|
|
|
17
16
|
bfc.purge()
|
|
18
17
|
|
|
@@ -22,16 +21,16 @@ def test_add_get_operations():
|
|
|
22
21
|
|
|
23
22
|
bfc.add("test1", os.getcwd() + "/tests/data/test1.txt")
|
|
24
23
|
rec1 = bfc.get("test1")
|
|
25
|
-
assert rec1
|
|
24
|
+
assert rec1 is not None
|
|
26
25
|
|
|
27
26
|
bfc.add("test2", os.getcwd() + "/tests/data/test2.txt")
|
|
28
27
|
rec2 = bfc.get("test2")
|
|
29
|
-
assert rec2
|
|
28
|
+
assert rec2 is not None
|
|
30
29
|
|
|
31
|
-
frec1 = open(rec1.rpath, "r").read()
|
|
30
|
+
frec1 = open(rec1.rpath, "r").read().strip()
|
|
32
31
|
assert frec1 == "test1"
|
|
33
32
|
|
|
34
|
-
frec2 = open(rec2.rpath, "r").read()
|
|
33
|
+
frec2 = open(rec2.rpath, "r").read().strip()
|
|
35
34
|
assert frec2 == "test2"
|
|
36
35
|
|
|
37
36
|
bfc.purge()
|
|
@@ -42,14 +41,14 @@ def test_remove_operations():
|
|
|
42
41
|
|
|
43
42
|
bfc.add("test1", os.getcwd() + "/tests/data/test1.txt")
|
|
44
43
|
rec1 = bfc.get("test1")
|
|
45
|
-
assert rec1
|
|
44
|
+
assert rec1 is not None
|
|
46
45
|
|
|
47
46
|
bfc.add("test2", os.getcwd() + "/tests/data/test2.txt")
|
|
48
47
|
rec2 = bfc.get("test2")
|
|
49
|
-
assert rec2
|
|
48
|
+
assert rec2 is not None
|
|
50
49
|
|
|
51
50
|
bfc.remove("test1")
|
|
52
51
|
rec1 = bfc.get("test1")
|
|
53
|
-
assert rec1
|
|
52
|
+
assert rec1 is None
|
|
54
53
|
|
|
55
54
|
bfc.purge()
|
pyBiocFileCache-0.2.2/temp.txt
DELETED
|
File without changes
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"""
|
|
2
|
-
Dummy conftest.py for pybiocfilecache.
|
|
3
|
-
|
|
4
|
-
If you don't know what this is for, just leave it empty.
|
|
5
|
-
Read more about conftest.py under:
|
|
6
|
-
- https://docs.pytest.org/en/stable/fixture.html
|
|
7
|
-
- https://docs.pytest.org/en/stable/writing_plugins.html
|
|
8
|
-
"""
|
|
9
|
-
|
|
10
|
-
# import pytest
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
test1
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
test2
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pyBiocFileCache-0.2.2 → pybiocfilecache-0.3.0}/src/pyBiocFileCache.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|