-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
48 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# pylint: disable=redefined-outer-name | ||
# pylint: disable=unused-argument | ||
# pylint: disable=unused-variable | ||
# pylint: disable=too-many-arguments | ||
|
||
|
||
from faker import Faker | ||
from simcore_postgres_database.utils import as_postgres_sql_query_str | ||
from simcore_service_storage.db_access_layer import _get_project_access_rights_stmt | ||
|
||
|
||
def test_build_access_rights_sql_statements(faker: Faker): | ||
def _check(func_smt, **kwargs): | ||
print() | ||
print(f"{func_smt.__name__:*^100}") | ||
stmt = func_smt(**kwargs) | ||
print() | ||
print(as_postgres_sql_query_str(stmt)) | ||
print() | ||
|
||
_check( | ||
_get_project_access_rights_stmt, | ||
user_id=42, | ||
project_id=faker.uuid4(), | ||
) |