Skip to content

Commit d8478d7

Browse files
author
Ajay Kannan
committed
Update examples in package-info
1 parent bfae667 commit d8478d7

2 files changed

Lines changed: 14 additions & 10 deletions

File tree

  • gcloud-java-datastore/src/main/java/com/google/gcloud/datastore/testing
  • gcloud-java-storage/src/main/java/com/google/gcloud/storage/testing

gcloud-java-datastore/src/main/java/com/google/gcloud/datastore/testing/package-info.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,20 +18,22 @@
1818
* A testing helper for Google Cloud Datastore.
1919
*
2020
* <p>A simple usage example:
21+
* <p>Before the test:
2122
* <pre> {@code
2223
* LocalGcdHelper gcdHelper = LocalGcdHelper.start(PROJECT_ID, PORT_NUMBER);
2324
* DatastoreOptions options = DatastoreOptions.builder()
2425
* .projectId(PROJECT_ID)
2526
* .host("localhost:8080")
2627
* .build();
2728
* Datastore localDatastore = DatastoreFactory.instance().get(options);
29+
* } </pre>
2830
*
29-
* // Do tests
30-
*
31+
* <p>After the test:
32+
* <pre> {@code
3133
* gcdHelper.stop();
3234
* } </pre>
3335
*
34-
* @see <a href="https://github.com/GoogleCloudPlatform/gcloud-java/blob/master/TESTING.md">
36+
* @see <a href="https://github.com/GoogleCloudPlatform/gcloud-java/blob/master/TESTING.md#testing-code-that-uses-datastore">
3537
* gcloud-java tools for testing</a>
3638
*/
3739
package com.google.gcloud.datastore.testing;

gcloud-java-storage/src/main/java/com/google/gcloud/storage/testing/package-info.java

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,21 @@
1717
/**
1818
* A testing helper for Google Cloud Storage.
1919
*
20-
* <p>A simple usage example, after setting the required environment variables (see the link below):
20+
* <p>A simple usage example:
21+
* <p>Before the test:
2122
* <pre> {@code
22-
* RemoteGcsHelper gcsHelper = RemoteGcsHelper.create();
23+
* RemoteGcsHelper gcsHelper = RemoteGcsHelper.create(PROJECT_ID, "/path/to/JSON/key.json");
2324
* Storage storage = StorageFactory.instance().get(gcsHelper.options());
2425
* String bucket = RemoteGcsHelper.generateBucketName();
2526
* storage.create(BucketInfo.of(bucket));
26-
*
27-
* // Do tests
28-
*
27+
* } </pre>
28+
*
29+
* <p>After the test:
30+
* <pre> {@code
2931
* RemoteGcsHelper.forceDelete(storage, bucket, 5, TimeUnit.SECONDS);
3032
* } </pre>
3133
*
32-
* @see <a href="https://github.com/GoogleCloudPlatform/gcloud-java/blob/master/TESTING.md">
34+
* @see <a href="https://github.com/GoogleCloudPlatform/gcloud-java/blob/master/TESTING.md#testing-code-that-uses-storage">
3335
* gcloud-java tools for testing</a>
3436
*/
35-
package com.google.gcloud.storage.testing;
37+
package com.google.gcloud.storage.testing;

0 commit comments

Comments
 (0)