Incrementally add more testing infrastructure

This commit is contained in:
Soby Chacko
2018-08-21 17:48:21 -04:00
parent d3d3318c6c
commit 6b2ff28b4b
11 changed files with 168 additions and 12 deletions

View File

@@ -23,7 +23,7 @@ import static org.junit.Assert.fail;
/**
* @author Soby Chacko
*/
public class TickTockAcceptanceTests extends AbstractAcceptanceTests {
public class TickTock13AcceptanceTests extends AbstractAcceptanceTests {
@Test
public void testTickTock13Rabbit() {

View File

@@ -0,0 +1,46 @@
/*
* Copyright 2018 the original author or authors.
*
* 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 sample.acceptance.tests;
import org.junit.Test;
import static org.junit.Assert.fail;
public class TickTockLatestAcceptanceTests extends AbstractAcceptanceTests {
@Test
public void testTickTockLatestRabbit() {
String timeSourceUrl = System.getProperty("time.source.route");
String logSinkUrl = System.getProperty("log.sink.route");
boolean foundLogs = waitForLogEntry("Time Source", timeSourceUrl, "Started TimeSource");
if(!foundLogs) {
fail("Did not find the time source started logging message.");
}
foundLogs = waitForLogEntry("Log Sink", logSinkUrl, "Started LogSink");
if(!foundLogs) {
fail("Did not find the log sink started logging message.");
}
foundLogs = waitForLogEntry("Log Sink", logSinkUrl, "TICKTOCK - TIMESTAMP:");
if(!foundLogs) {
fail("Did not find the ticktock messages in log sink");
}
}
}