Skip to content

Commit 4054e3d

Browse files
committed
Add integration tests to pubsub
1 parent 42f0fe8 commit 4054e3d

2 files changed

Lines changed: 46 additions & 1 deletion

File tree

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ before_install:
99
- cp target/travis/settings.xml ~/.m2/settings.xml
1010
install: mvn install -DskipTests=true -Dgpg.skip=true
1111
script:
12-
- travis_wait 30 utilities/verify.sh
12+
- travis_wait 60 utilities/verify.sh
1313
after_success:
1414
- utilities/after_success.sh
1515
env:
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
/*
2+
* Copyright 2016 Google Inc. All Rights Reserved.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
package com.google.cloud.pubsub.it;
18+
19+
import com.google.cloud.pubsub.BaseSystemTest;
20+
import com.google.cloud.pubsub.PubSub;
21+
import com.google.cloud.pubsub.PubSubOptions;
22+
23+
import org.junit.Rule;
24+
import org.junit.rules.Timeout;
25+
26+
import java.util.UUID;
27+
28+
public class ITPubSubTest extends BaseSystemTest {
29+
30+
private static final PubSub PUB_SUB = PubSubOptions.defaultInstance().service();
31+
private static final String NAME_SUFFIX = UUID.randomUUID().toString();
32+
33+
@Rule
34+
public Timeout globalTimeout = Timeout.seconds(300);
35+
36+
@Override
37+
protected PubSub pubsub() {
38+
return PUB_SUB;
39+
}
40+
41+
@Override
42+
protected String formatForTest(String resourceName) {
43+
return resourceName + "-" + NAME_SUFFIX;
44+
}
45+
}

0 commit comments

Comments
 (0)