Skip to content

Commit

Permalink
Remove subprocess call causing gh action tests to fail
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonscript committed Apr 8, 2024
1 parent 9d370ab commit afa79ac
Showing 1 changed file with 2 additions and 15 deletions.
17 changes: 2 additions & 15 deletions tests/test_tinta.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@

import os
import re
import subprocess
import time
import timeit
from contextlib import contextmanager
Expand Down Expand Up @@ -107,25 +106,13 @@ def test_reloads_colors(self, alt_colors_ini):
Tinta().inspect(name="grey")
Tinta.load_colors("examples/colors.ini")
Tinta().inspect(name="grey")
Tinta.load_colors("examples/colors.ini")
Tinta().inspect(name="grey")
Tinta.load_colors(alt_colors_ini)
Tinta().inspect(name="sparkle")
Tinta.load_colors("examples/colors.ini")
Tinta().inspect(name="grey")

try:
subprocess.check_output(
"""pipenv run python -c \"from tinta import Tinta
Tinta.load_colors('examples/colors.ini')
Tinta.load_colors('examples/colors.ini')
Tinta().inspect(name='grey')
Tinta().grey('grey').print()\"""",
shell=True,
stderr=subprocess.STDOUT,
env=os.environ,
)
except subprocess.CalledProcessError as e:
raise Exception(e.stdout)

def test_loads_colors_with_clobbering(self, clobber_colors_ini):
with pytest.raises(AttributeError, match="Cannot overwrite built-in method"):
Tinta.load_colors(clobber_colors_ini)
Expand Down

0 comments on commit afa79ac

Please sign in to comment.