Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added caching of cffstr during tests #365

Merged
merged 1 commit into from
Sep 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_apalike_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.apalike import ApalikeObject
from tests.lib.contracts.apalike import Contract


@lru_cache
def apalike_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_bibtex_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.bibtex import BibtexObject
from tests.lib.contracts.bibtex import Contract


@lru_cache
def bibtex_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_codemeta_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.codemeta import CodemetaObject
from tests.lib.contracts.codemeta import Contract


@lru_cache
def codemeta_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_endnote_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.endnote import EndnoteObject
from tests.lib.contracts.endnote import Contract


@lru_cache
def endnote_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_ris_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.ris import RisObject
from tests.lib.contracts.ris import Contract


@lru_cache
def ris_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_schemaorg_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.schemaorg import SchemaorgObject
from tests.lib.contracts.schemaorg import Contract


@lru_cache
def schemaorg_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/a/test_zenodo_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.zenodo import ZenodoObject
from tests.lib.contracts.zenodo import Contract


@lru_cache
def zenodo_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_apalike_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.apalike import ApalikeObject
from tests.lib.contracts.apalike import Contract


@lru_cache
def apalike_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_bibtex_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.bibtex import BibtexObject
from tests.lib.contracts.bibtex import Contract


@lru_cache
def bibtex_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_codemeta_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.codemeta import CodemetaObject
from tests.lib.contracts.codemeta import Contract


@lru_cache
def codemeta_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_endnote_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.endnote import EndnoteObject
from tests.lib.contracts.endnote import Contract


@lru_cache
def endnote_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_ris_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.ris import RisObject
from tests.lib.contracts.ris import Contract


@lru_cache
def ris_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_schemaorg_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.schemaorg import SchemaorgObject
from tests.lib.contracts.schemaorg import Contract


@lru_cache
def schemaorg_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/b/test_zenodo_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.zenodo import ZenodoObject
from tests.lib.contracts.zenodo import Contract


@lru_cache
def zenodo_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_apalike_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.apalike import ApalikeObject
from tests.lib.contracts.apalike import Contract


@lru_cache
def apalike_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_bibtex_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.bibtex import BibtexObject
from tests.lib.contracts.bibtex import Contract


@lru_cache
def bibtex_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_codemeta_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.codemeta import CodemetaObject
from tests.lib.contracts.codemeta import Contract


@lru_cache
def codemeta_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_endnote_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.endnote import EndnoteObject
from tests.lib.contracts.endnote import Contract


@lru_cache
def endnote_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_ris_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.ris import RisObject
from tests.lib.contracts.ris import Contract


@lru_cache
def ris_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_schemaorg_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.schemaorg import SchemaorgObject
from tests.lib.contracts.schemaorg import Contract


@lru_cache
def schemaorg_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/c/test_zenodo_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.zenodo import ZenodoObject
from tests.lib.contracts.zenodo import Contract


@lru_cache
def zenodo_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_apalike_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.apalike import ApalikeObject
from tests.lib.contracts.apalike import Contract


@lru_cache
def apalike_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_bibtex_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.bibtex import BibtexObject
from tests.lib.contracts.bibtex import Contract


@lru_cache
def bibtex_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_codemeta_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.codemeta import CodemetaObject
from tests.lib.contracts.codemeta import Contract


@lru_cache
def codemeta_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_endnote_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.endnote import EndnoteObject
from tests.lib.contracts.endnote import Contract


@lru_cache
def endnote_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_ris_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.ris import RisObject
from tests.lib.contracts.ris import Contract


@lru_cache
def ris_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_schemaorg_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.schemaorg import SchemaorgObject
from tests.lib.contracts.schemaorg import Contract


@lru_cache
def schemaorg_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/d/test_zenodo_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.zenodo import ZenodoObject
from tests.lib.contracts.zenodo import Contract


@lru_cache
def zenodo_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/e/test_apalike_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.apalike import ApalikeObject
from tests.lib.contracts.apalike import Contract


@lru_cache
def apalike_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
2 changes: 2 additions & 0 deletions tests/lib/cff_1_0_3/e/test_bibtex_object.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import os
from functools import lru_cache
import pytest
from cffconvert import Citation
from cffconvert.lib.cff_1_0_x.bibtex import BibtexObject
from tests.lib.contracts.bibtex import Contract


@lru_cache
def bibtex_object():
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "rt", encoding="utf-8") as f:
Expand Down
Loading
Loading