Skip to content

Commit

Permalink
Client SQL removed
Browse files Browse the repository at this point in the history
  • Loading branch information
ADIMANV committed Sep 24, 2024
1 parent d8ea310 commit 18449f1
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions database-cleanup/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import pytest
import sqlalchemy as sa
from pvsite_datamodel.sqlmodels import Base, ClientSQL, SiteSQL
from pvsite_datamodel.sqlmodels import Base, SiteSQL
from sqlalchemy.orm import Session
from testcontainers.postgres import PostgresContainer

Expand All @@ -29,11 +29,9 @@ def fill_db(engine):
num_sites = 3
with Session(engine) as session:
for i in range(num_clients):
client = ClientSQL(client_name=f"client-{i}")
session.add(client)
session.commit()
for j in range(num_sites):
session.add(SiteSQL(client_uuid=client.client_uuid, ml_id=j + num_sites * i))
session.add(SiteSQL(ml_id=j + num_sites * i))
session.commit()


Expand Down

0 comments on commit 18449f1

Please sign in to comment.