Skip to content

Commit 0aa9a44

Browse files
committed
almost there
1 parent 43ffe64 commit 0aa9a44

File tree

10 files changed

+3
-581
lines changed

10 files changed

+3
-581
lines changed

β€Žtests/performance/Makefileβ€Ž

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ test-deployment: _check_venv_active ## runs deployment test on deploy
9797
@$(call prompt_for_credentials)
9898
@$(call create_locust_config)
9999
@printf "$(YELLOW)Starting Locust...$(NC)\n"
100+
@xdg-open http://localhost:8089/ &
100101
@export $$(cat $(AUTH_CREDS_FILE) | xargs) && \
101102
locust --config $(LOCUST_CONFIG_FILE)
102103

@@ -111,6 +112,7 @@ test-deployment-with-grafana: _check_venv_active grafana-dashboards-up ## runs d
111112
@$(call prompt_for_credentials)
112113
@$(call create_locust_config)
113114
@printf "$(YELLOW)Starting Locust with Grafana integration...$(NC)\n"
115+
@xdg-open $(GRAFANA_URL)
114116
@export $$(cat $(AUTH_CREDS_FILE) | xargs) && \
115117
locust --config $(LOCUST_CONFIG_FILE) \
116118
--grafana-url $(GRAFANA_URL) \

β€Žtests/performance/locustfiles/deployment_max_rps_single_endpoint.pyβ€Ž

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,6 @@ def _(environment, **_kwargs) -> None:
4646

4747

4848
class WebApiUser(OsparcWebUserBase):
49-
def __init__(self, *args, **kwargs):
50-
super().__init__(*args, **kwargs)
51-
5249
@task
5350
def get_endpoint(self) -> None:
5451
self.authenticated_get(self.environment.parsed_options.endpoint)

β€Žtests/performance/locustfiles/webserver_services.pyβ€Ž

Lines changed: 1 addition & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
from common.base_user import OsparcWebUserBase
1212
from dotenv import load_dotenv
1313

14-
logging.basicConfig(level=logging.INFO)
14+
_logger = logging.getLogger(__name__)
1515

1616
fake = faker.Faker()
1717

@@ -44,33 +44,3 @@ def list_latest_services(self):
4444
parsed_next = urllib.parse.urlparse(next_link)
4545
base_url = parsed_next.path
4646
params = dict(urllib.parse.parse_qsl(parsed_next.query))
47-
48-
def on_start(self):
49-
logging.info("Creating user with email: %s", self.email)
50-
51-
# Register user
52-
self.authenticated_post(
53-
"/v0/auth/register",
54-
json={
55-
"email": self.email,
56-
"password": self.password,
57-
"confirm": self.password,
58-
},
59-
)
60-
61-
# Login using the custom user credentials instead of the default ones
62-
logging.info("Logging in user with email: %s", self.email)
63-
response = self.authenticated_post(
64-
"/v0/auth/login",
65-
json={
66-
"email": self.email,
67-
"password": self.password,
68-
},
69-
)
70-
response.raise_for_status()
71-
logging.info("Logged in user with email: %s", self.email)
72-
73-
def on_stop(self):
74-
# Logout
75-
self.authenticated_post("/v0/auth/logout")
76-
logging.info("Logged out user with email: %s", self.email)

β€Žtests/performance_old/Makefileβ€Ž

Lines changed: 0 additions & 101 deletions
This file was deleted.

β€Žtests/performance_old/README.mdβ€Ž

Lines changed: 0 additions & 33 deletions
This file was deleted.

β€Žtests/performance_old/locust_files/catalog_services.pyβ€Ž

Lines changed: 0 additions & 57 deletions
This file was deleted.

β€Žtests/performance_old/locust_files/director_services.pyβ€Ž

Lines changed: 0 additions & 31 deletions
This file was deleted.

β€Žtests/performance_old/locust_files/locustfile.pyβ€Ž

Lines changed: 0 additions & 76 deletions
This file was deleted.

0 commit comments

Comments
Β (0)