Skip to content

Commit

Permalink
test: fixed github actions secrets again
Browse files Browse the repository at this point in the history
  • Loading branch information
pruizlezcano committed Jul 11, 2023
1 parent 2f8ce3c commit 8b95823
Show file tree
Hide file tree
Showing 6 changed files with 45 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ jobs:
with: {name: python-distribution-files, path: dist/}
- name: Run tests
env:
CI_SESSION: ${{ secrets.LCG_CI_SESSION }}
USERNAME: ${{ secrets.LCG_USERNAME }}
PASSWORD: ${{ secrets.LCG_PASSWORD }}
LCG_CI_SESSION: ${{ secrets.LCG_CI_SESSION }}
LCG_USERNAME: ${{ secrets.LCG_USERNAME }}
LCG_PASSWORD: ${{ secrets.LCG_PASSWORD }}
run: >-
pipx run tox
--installpkg '${{ needs.prepare.outputs.wheel-distribution }}'
Expand Down
8 changes: 8 additions & 0 deletions tests/test_Character.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@

dotenv_path = Path(".devdata.env")
env = dotenv_values(dotenv_path=dotenv_path)
if "LCG_CI_SESSION" not in env:
import os

env = {
"LCG_CI_SESSION": os.environ.get("LCG_CI_SESSION"),
"LCG_USERNAME": os.environ.get("LCG_USERNAME"),
"LCG_PASSWORD": os.environ.get("LCG_PASSWORD"),
}

__author__ = "Pablo Ruiz"
__copyright__ = "Pablo Ruiz"
Expand Down
10 changes: 9 additions & 1 deletion tests/test_Issue.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@

dotenv_path = Path(".devdata.env")
env = dotenv_values(dotenv_path=dotenv_path)
if "LCG_CI_SESSION" not in env:
import os

env = {
"LCG_CI_SESSION": os.environ.get("LCG_CI_SESSION"),
"LCG_USERNAME": os.environ.get("LCG_USERNAME"),
"LCG_PASSWORD": os.environ.get("LCG_PASSWORD"),
}

__author__ = "Pablo Ruiz"
__copyright__ = "Pablo Ruiz"
Expand Down Expand Up @@ -68,7 +76,7 @@ def test_get_issue_by_id():
pagination.keys(),
)
)
assert data["store_date"] == 1563314400
assert data["store_date"] == 1563321600
assert data["url"] == "/comic/3616996/daredevil-8"
assert len(data["variant_covers"]) >= 2
user = data["user"]
Expand Down
8 changes: 8 additions & 0 deletions tests/test_Series.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@

dotenv_path = Path(".devdata.env")
env = dotenv_values(dotenv_path=dotenv_path)
if "LCG_CI_SESSION" not in env:
import os

env = {
"LCG_CI_SESSION": os.environ.get("LCG_CI_SESSION"),
"LCG_USERNAME": os.environ.get("LCG_USERNAME"),
"LCG_PASSWORD": os.environ.get("LCG_PASSWORD"),
}

__author__ = "Pablo Ruiz"
__copyright__ = "Pablo Ruiz"
Expand Down
10 changes: 9 additions & 1 deletion tests/test_TradePaperback.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@

dotenv_path = Path(".devdata.env")
env = dotenv_values(dotenv_path=dotenv_path)
if "LCG_CI_SESSION" not in env:
import os

env = {
"LCG_CI_SESSION": os.environ.get("LCG_CI_SESSION"),
"LCG_USERNAME": os.environ.get("LCG_USERNAME"),
"LCG_PASSWORD": os.environ.get("LCG_PASSWORD"),
}

__author__ = "Pablo Ruiz"
__copyright__ = "Pablo Ruiz"
Expand Down Expand Up @@ -74,7 +82,7 @@ def test_get_trade_paperback_by_id():
pagination.keys(),
)
)
assert data["store_date"] == 1690236000
assert data["store_date"] == 1690243200
assert (
data["url"]
== "/comic/6828314/daredevil-elektra-by-chip-zdarsky-vol-2-the-red-fist-saga-part-two-tp"
Expand Down
8 changes: 8 additions & 0 deletions tests/test_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@

dotenv_path = Path(".devdata.env")
env = dotenv_values(dotenv_path=dotenv_path)
if "LCG_CI_SESSION" not in env:
import os

env = {
"LCG_CI_SESSION": os.environ.get("LCG_CI_SESSION"),
"LCG_USERNAME": os.environ.get("LCG_USERNAME"),
"LCG_PASSWORD": os.environ.get("LCG_PASSWORD"),
}

__author__ = "Pablo Ruiz"
__copyright__ = "Pablo Ruiz"
Expand Down

0 comments on commit 8b95823

Please sign in to comment.