mirror of
https://git.zavage.net/Zavage-Software/smileyface.git
synced 2026-06-25 18:12:48 -06:00
build: cleanup for new selenium and guards
Some checks failed
tests / test (3.10) (push) Has been cancelled
tests / test (3.11) (push) Has been cancelled
tests / test (3.12) (push) Has been cancelled
tests / test (3.13) (push) Has been cancelled
tests / test (3.8) (push) Has been cancelled
tests / test (3.9) (push) Has been cancelled
Some checks failed
tests / test (3.10) (push) Has been cancelled
tests / test (3.11) (push) Has been cancelled
tests / test (3.12) (push) Has been cancelled
tests / test (3.13) (push) Has been cancelled
tests / test (3.8) (push) Has been cancelled
tests / test (3.9) (push) Has been cancelled
This commit is contained in:
parent
bb7325008b
commit
0c8fa30145
@ -1,5 +1,6 @@
|
||||
import selenium
|
||||
import selenium.webdriver
|
||||
from selenium.webdriver.common.by import By
|
||||
|
||||
URL_MUTATORS = "https://ut4pugs.us/redirect-mutators"
|
||||
URL_MAPS = "https://ut4pugs.us/redirect-mutators"
|
||||
@ -25,12 +26,12 @@ class ScrapeUt4Pugs:
|
||||
self._check_pak_md5sums()
|
||||
|
||||
def _check_pak_md5sums(self):
|
||||
tbl_of_mutators = self.browser.find_element_by_id("myTable")
|
||||
tbl_of_mutators = self.browser.find_element(By.ID, "myTable")
|
||||
print(tbl_of_mutators)
|
||||
|
||||
mut_rows = tbl_of_mutators.find_elements_by_xpath("tbody/tr")
|
||||
mut_rows = tbl_of_mutators.find_elements(By.XPATH, "tbody/tr")
|
||||
for r in mut_rows:
|
||||
mut_cols = r.find_elements_by_xpath("td")
|
||||
mut_cols = r.find_elements(By.XPATH, "td")
|
||||
if len(mut_cols) != 3:
|
||||
input("<breakpoint> at unexpected columns for mutator. received {}".format(len(mut_cols)))
|
||||
mut_file = mut_cols[0]
|
||||
|
||||
@ -1,7 +1,16 @@
|
||||
import os
|
||||
|
||||
from smileyface.settings import AppSettings
|
||||
|
||||
|
||||
def test_defaults():
|
||||
def _clear_smileyface_env(monkeypatch):
|
||||
for key in list(os.environ):
|
||||
if key.startswith("SMILEYFACE_"):
|
||||
monkeypatch.delenv(key, raising=False)
|
||||
|
||||
|
||||
def test_defaults(monkeypatch):
|
||||
_clear_smileyface_env(monkeypatch)
|
||||
settings = AppSettings(_env_file=None)
|
||||
assert settings.sqlite_filename == "smiles.db"
|
||||
assert settings.skip_validate is False
|
||||
@ -9,6 +18,7 @@ def test_defaults():
|
||||
|
||||
|
||||
def test_env_overrides(monkeypatch):
|
||||
_clear_smileyface_env(monkeypatch)
|
||||
monkeypatch.setenv("SMILEYFACE_PROJECT_DIR", "/srv/ut4")
|
||||
monkeypatch.setenv("SMILEYFACE_SKIP_VALIDATE", "true")
|
||||
settings = AppSettings(_env_file=None)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user