Skip to content

Commit

Permalink
Merge pull request #7282 from zregvart/issue/ENTESB-12192
Browse files Browse the repository at this point in the history
  • Loading branch information
pure-bot[bot] committed Nov 29, 2019
2 parents 478bab3 + cbd79c7 commit b347eef
Show file tree
Hide file tree
Showing 4 changed files with 1,702 additions and 2 deletions.
3 changes: 1 addition & 2 deletions app/connector/gmail/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
<name>Connector :: Gmail</name>
<packaging>jar</packaging>


<dependencyManagement>
<dependencies>
<dependency>
Expand Down Expand Up @@ -76,7 +75,7 @@
<dependency>
<groupId>com.google.apis</groupId>
<artifactId>google-api-services-gmail</artifactId>
<version>v1-rev20190602-1.30.1</version>
<version>v1-rev81-1.22.0</version>
</dependency>
<dependency>
<groupId>com.google.http-client</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* Copyright (C) 2016 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package io.syndesis.test.itest.gmail;

import io.syndesis.test.SyndesisTestEnvironment;
import io.syndesis.test.container.integration.SyndesisIntegrationRuntimeContainer;
import io.syndesis.test.itest.SyndesisIntegrationTestSupport;

import org.junit.ClassRule;
import org.junit.Test;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpStatus;

import com.consol.citrus.annotations.CitrusResource;
import com.consol.citrus.annotations.CitrusTest;
import com.consol.citrus.dsl.runner.TestRunner;

public class WebhookToGMail_IT extends SyndesisIntegrationTestSupport {

/**
* Webhook receives POST request and sends an e-mail via GMail REST API.
*/
@ClassRule
public static SyndesisIntegrationRuntimeContainer integrationContainer = new SyndesisIntegrationRuntimeContainer.Builder()
.name("webhook-to-gmail")
.fromExport(WebhookToGMail_IT.class.getResource("webhook-to-gmail-export"))
.build()
.withExposedPorts(SyndesisTestEnvironment.getServerPort(),
SyndesisTestEnvironment.getManagementPort());

@Test
@CitrusTest
public void waitForIntegrationToBeHealthy(@CitrusResource final TestRunner runner) {
runner.waitFor().http()
.method(HttpMethod.GET)
.seconds(10L)
.status(HttpStatus.OK)
.url(String.format("http://localhost:%s/health", integrationContainer.getManagementPort()));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"schemaVersion":32}

0 comments on commit b347eef

Please sign in to comment.