Skip to content

Commit 5a6e60c

Browse files
committed
misc fixes to get end to end tests to pass
1 parent a0d571c commit 5a6e60c

File tree

6 files changed

+38
-7
lines changed

6 files changed

+38
-7
lines changed

build-and-test-all.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,19 +54,19 @@ if [ -z "$ASSEMBLE_ONLY" ] ; then
5454
./gradlew infrastructureComposeDown
5555
./gradlew infrastructureComposeUp
5656

57-
./gradlew cleanComponentTest componentTest
57+
./gradlew cleanComponentTest
5858

59-
./gradlew infrastructureComposeDown
60-
61-
./gradlew composeUp
59+
# ./gradlew :ftgo-delivery-service:componentTest
60+
# ./gradlew :ftgo-order-service:componentTest
61+
62+
./gradlew componentTest
6263

64+
./gradlew infrastructureComposeDown
6365

6466
else
6567

6668
./gradlew $* assemble
6769

68-
./gradlew composeUp
69-
7070
fi
7171

7272
./run-end-to-end-tests.sh

ftgo-delivery-service/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ dockerCompose {
4848
environment.put "EVENTUATE_SAGA_VERSION", eventuateTramSagasImageVersion
4949
environment.put "EVENTUATE_JAVA_BASE_IMAGE_VERSION", eventuateExamplesBaseImageVersion
5050
environment.put "EVENTUATE_MESSAGING_KAFKA_IMAGE_VERSION", eventuateMessagingKafkaImageVersion
51+
52+
projectName = null
5153

5254
componentTests {
5355
projectName = null

ftgo-delivery-service/src/component-test/java/net/chrisrichardson/ftgo/deliveryservice/RestaurantEventMother.java

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,34 @@
33
import net.chrisrichardson.ftgo.deliveryservice.domain.DeliveryServiceTestData;
44
import net.chrisrichardson.ftgo.deliveryservice.messaging.RestaurantEventMapper;
55
import net.chrisrichardson.ftgo.restaurantservice.events.RestaurantCreated;
6+
import net.chrisrichardson.ftgo.restaurantservice.events.Menu;
7+
import net.chrisrichardson.ftgo.restaurantservice.events.MenuItem;
8+
9+
import java.util.Collections;
10+
import java.util.List;
11+
12+
import net.chrisrichardson.ftgo.common.Address;
13+
import net.chrisrichardson.ftgo.common.Money;
614

715
public class RestaurantEventMother {
16+
17+
public static final String CHICKEN_VINDALOO = "Chicken Vindaloo";
18+
public static final String CHICKEN_VINDALOO_MENU_ITEM_ID = "1";
19+
public static final String CHICKEN_VINDALOO_PRICE = "12.34";
20+
public static final Address RESTAURANT_ADDRESS = new Address("1 Main Street", "Unit 99", "Oakland", "CA", "94611");
21+
22+
public static MenuItem CHICKEN_VINDALOO_MENU_ITEM = new MenuItem()
23+
.withId(CHICKEN_VINDALOO_MENU_ITEM_ID)
24+
.withName(CHICKEN_VINDALOO)
25+
.withPrice(CHICKEN_VINDALOO_PRICE);
26+
27+
public static final List<MenuItem> AJANTA_RESTAURANT_MENU_ITEMS = Collections.singletonList(CHICKEN_VINDALOO_MENU_ITEM);
28+
29+
830
static RestaurantCreated makeRestaurantCreated() {
931
return new RestaurantCreated()
1032
.withName("Delicious Indian")
11-
.withAddress(RestaurantEventMapper.fromAddress(DeliveryServiceTestData.PICKUP_ADDRESS)).withMenu(null);
33+
.withAddress(RestaurantEventMapper.fromAddress(DeliveryServiceTestData.PICKUP_ADDRESS))
34+
.withMenu(new Menu().withMenuItems(AJANTA_RESTAURANT_MENU_ITEMS));
1235
}
1336
}

ftgo-order-history-service/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ dockerCompose {
6969
environment.put "EVENTUATE_JAVA_BASE_IMAGE_VERSION", eventuateExamplesBaseImageVersion
7070
environment.put "EVENTUATE_MESSAGING_KAFKA_IMAGE_VERSION", eventuateMessagingKafkaImageVersion
7171

72+
projectName = null
73+
7274
integrationTests {
7375
projectName = null
7476
removeOrphans = true

ftgo-order-service/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@ dockerCompose {
6767
environment.put "EVENTUATE_JAVA_BASE_IMAGE_VERSION", eventuateExamplesBaseImageVersion
6868
environment.put "EVENTUATE_MESSAGING_KAFKA_IMAGE_VERSION", eventuateMessagingKafkaImageVersion
6969

70+
projectName = null
71+
7072
integrationTests {
7173
projectName = null
7274
removeOrphans = true

ftgo-restaurant-service-aws-lambda/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ dockerCompose {
4343
environment.put "EVENTUATE_JAVA_BASE_IMAGE_VERSION", eventuateExamplesBaseImageVersion
4444
environment.put "EVENTUATE_MESSAGING_KAFKA_IMAGE_VERSION", eventuateMessagingKafkaImageVersion
4545

46+
projectName = null
47+
4648
integrationTests {
4749
projectName = null
4850
removeOrphans = true

0 commit comments

Comments
 (0)