File tree 1 file changed +6
-2
lines changed
bigquery-reservation/snippets
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -44,13 +44,17 @@ def location_path(project_id: str, location: str) -> str:
44
44
45
45
46
46
@pytest .fixture (scope = "session" , autouse = True )
47
- def capacity_commitment (location_path : str , reservation_client : reservation_service .ReservationServiceClient ) -> reservation_types .CapacityCommitment :
47
+ def capacity_commitment (
48
+ location_path : str , reservation_client : reservation_service .ReservationServiceClient
49
+ ) -> reservation_types .CapacityCommitment :
48
50
# TODO(b/196082966): If custom names or creation date property are added,
49
51
# do pre-test cleanup of past commitments.
50
52
commitment = reservation_types .CapacityCommitment ()
51
53
commitment .slot_count = 100
52
54
commitment .plan = reservation_types .CapacityCommitment .CommitmentPlan .FLEX
53
- commitment = reservation_client .create_capacity_commitment (parent = location_path , capacity_commitment = commitment )
55
+ commitment = reservation_client .create_capacity_commitment (
56
+ parent = location_path , capacity_commitment = commitment
57
+ )
54
58
yield commitment
55
59
# Commitments can only be removed after 1 minute.
56
60
now = datetime .datetime .now (datetime .timezone .utc )
You can’t perform that action at this time.
0 commit comments