Skip to content

Commit

Permalink
fix: respond to comments
Browse files Browse the repository at this point in the history
  • Loading branch information
fstagni committed Aug 28, 2024
1 parent 800ecea commit 5ad0b66
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 12 deletions.
7 changes: 0 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,3 @@ repos:
- types-aiobotocore[essential]
- boto3-stubs[essential]
exclude: ^(diracx-client/src/diracx/client/|diracx-[a-z]+/tests/|diracx-testing/|build)

- repo: https://github.com/asottile/pyupgrade
rev: v3.17.0
hooks:
- id: pyupgrade
args: ["--py311-plus"]
exclude: ^(diracx-client/src/diracx/client/|diracx-cli/tests/|diracx-cli/src/diracx/cli/)
4 changes: 2 additions & 2 deletions diracx-api/tests/test_jobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ async def test_upload_download_sandbox(tmp_path, with_cli_login, caplog):
input_files = []

input_file = input_directory / "input.dat"
input_file.write_bytes(secrets.token_bytes(1024))
input_file.write_bytes(secrets.token_bytes(512))
input_files.append(input_file)

input_file = input_directory / "a" / "b" / "c" / "nested.dat"
input_file.parent.mkdir(parents=True)
input_file.write_bytes(secrets.token_bytes(1024))
input_file.write_bytes(secrets.token_bytes(512))
input_files.append(input_file)

# Upload the sandbox
Expand Down
6 changes: 3 additions & 3 deletions diracx-routers/tests/jobs/test_sandboxes.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def normal_user_client(client_factory):
def test_upload_then_download(
normal_user_client: TestClient, test_auth_settings: AuthSettings
):
data = secrets.token_bytes(1024)
data = secrets.token_bytes(512)
checksum = hashlib.sha256(data).hexdigest()

# Initiate the upload
Expand Down Expand Up @@ -85,7 +85,7 @@ def test_upload_then_download(


def test_upload_oversized(normal_user_client: TestClient):
data = secrets.token_bytes(1024)
data = secrets.token_bytes(512)
checksum = hashlib.sha256(data).hexdigest()

# Initiate the upload
Expand Down Expand Up @@ -125,7 +125,7 @@ def test_upload_oversized(normal_user_client: TestClient):


def test_assign_then_unassign_sandboxes_to_jobs(normal_user_client: TestClient):
data = secrets.token_bytes(1024)
data = secrets.token_bytes(512)
checksum = hashlib.sha256(data).hexdigest()

# Upload Sandbox:
Expand Down

0 comments on commit 5ad0b66

Please sign in to comment.