Skip to content

Commit 9058d90

Browse files
committed
refactor(tests/nixos/s3-binary-cache-store): rename populate_with to populate_bucket
1 parent c1a15d1 commit 9058d90

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

tests/nixos/s3-binary-cache-store.nix

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -135,22 +135,22 @@ in
135135
print(output)
136136
raise Exception(f"{error_msg}: expected {expected}, got {actual}")
137137
138-
def setup_s3(populate_with=[]):
138+
def setup_s3(populate_bucket=[]):
139139
"""
140140
Decorator that creates/destroys a unique bucket for each test.
141141
Optionally pre-populates bucket with specified packages.
142142
143143
Args:
144-
populate_with: List of packages to upload before test runs
144+
populate_bucket: List of packages to upload before test runs
145145
"""
146146
def decorator(test_func):
147147
def wrapper():
148148
bucket = str(uuid.uuid4())
149149
server.succeed(f"mc mb minio/{bucket}")
150150
try:
151-
if populate_with:
151+
if populate_bucket:
152152
store_url = make_s3_url(bucket)
153-
for pkg in populate_with:
153+
for pkg in populate_bucket:
154154
server.succeed(f"{ENV_WITH_CREDS} nix copy --to '{store_url}' {pkg}")
155155
test_func(bucket)
156156
finally:
@@ -182,7 +182,7 @@ in
182182
183183
print("✓ Credential provider created once and cached")
184184
185-
@setup_s3(populate_with=[PKGS['A']])
185+
@setup_s3(populate_bucket=[PKGS['A']])
186186
def test_fetchurl_basic(bucket):
187187
"""Test builtins.fetchurl works with s3:// URLs"""
188188
print("\n=== Testing builtins.fetchurl ===")
@@ -218,7 +218,7 @@ in
218218
219219
print("✓ Error messages format URLs correctly")
220220
221-
@setup_s3(populate_with=[PKGS['A']])
221+
@setup_s3(populate_bucket=[PKGS['A']])
222222
def test_fork_credential_preresolution(bucket):
223223
"""Test credential pre-resolution in forked processes"""
224224
print("\n=== Testing Fork Credential Pre-resolution ===")
@@ -298,7 +298,7 @@ in
298298
299299
print(" ✓ Child uses pre-resolved credentials (no new providers)")
300300
301-
@setup_s3(populate_with=[PKGS['A'], PKGS['B'], PKGS['C']])
301+
@setup_s3(populate_bucket=[PKGS['A'], PKGS['B'], PKGS['C']])
302302
def test_store_operations(bucket):
303303
"""Test nix store info and copy operations"""
304304
print("\n=== Testing Store Operations ===")
@@ -337,7 +337,7 @@ in
337337
print(" ✓ nix copy works")
338338
print(" ✓ Credentials cached on client")
339339
340-
@setup_s3(populate_with=[PKGS['A']])
340+
@setup_s3(populate_bucket=[PKGS['A']])
341341
def test_url_format_variations(bucket):
342342
"""Test different S3 URL parameter combinations"""
343343
print("\n=== Testing URL Format Variations ===")
@@ -352,7 +352,7 @@ in
352352
client.succeed(f"{ENV_WITH_CREDS} nix store info --store '{url2}' >&2")
353353
print(" ✓ Parameter order: endpoint before region works")
354354
355-
@setup_s3(populate_with=[PKGS['A']])
355+
@setup_s3(populate_bucket=[PKGS['A']])
356356
def test_concurrent_fetches(bucket):
357357
"""Validate thread safety with concurrent S3 operations"""
358358
print("\n=== Testing Concurrent Fetches ===")

0 commit comments

Comments
 (0)