Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
varuncnaik committed Aug 3, 2024
1 parent 5c1c33e commit 6a0b405
Showing 1 changed file with 13 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,24 @@ public void testCreateInstancePartition() throws Exception {
String instanceId = idGenerator.generateInstanceId();
InstanceAdminClient instanceAdminClient = spanner.getInstanceAdminClient();
instanceAdminClient
.createInstance(InstanceInfo.newBuilder(InstanceId.of(projectId, instanceId))
.setDisplayName("Geo-partitioning test instance")
.setInstanceConfigId(InstanceConfigId.of(projectId, "regional-us-central1"))
.setNodeCount(1).build())
.createInstance(
InstanceInfo.newBuilder(InstanceId.of(projectId, instanceId))
.setDisplayName("Geo-partitioning test instance")
.setInstanceConfigId(InstanceConfigId.of(projectId, "regional-us-central1"))
.setNodeCount(1)
.build())
.get();

String instancePartitionId = "my-instance-partition";
String out =
SampleRunner.runSample(
() -> CreateInstancePartitionSample.createInstancePartition(projectId, instanceId, instancePartitionId));
() ->
CreateInstancePartitionSample.createInstancePartition(
projectId, instanceId, instancePartitionId));
assertThat(out)
.contains(String.format("Instance partition %s",
InstancePartitionName.of(projectId, instanceId, instancePartitionId).toString()));
.contains(
String.format(
"Instance partition %s",
InstancePartitionName.of(projectId, instanceId, instancePartitionId).toString()));
}
}

0 comments on commit 6a0b405

Please sign in to comment.