From 6b5bc4e3242f175d39a9a2de23eced0b3a6b3d94 Mon Sep 17 00:00:00 2001 From: Sasa M Date: Tue, 9 Jun 2020 18:22:01 +0200 Subject: [PATCH] Unit test deleted in customer-service module --- .../CustomerServiceUnitTest.java | 33 ------------------- 1 file changed, 33 deletions(-) delete mode 100644 spring-cloud/spring-cloud-bootstrap/customer-service/src/test/java/com/baeldung/customerservice/CustomerServiceUnitTest.java diff --git a/spring-cloud/spring-cloud-bootstrap/customer-service/src/test/java/com/baeldung/customerservice/CustomerServiceUnitTest.java b/spring-cloud/spring-cloud-bootstrap/customer-service/src/test/java/com/baeldung/customerservice/CustomerServiceUnitTest.java deleted file mode 100644 index 6a8527c86e..0000000000 --- a/spring-cloud/spring-cloud-bootstrap/customer-service/src/test/java/com/baeldung/customerservice/CustomerServiceUnitTest.java +++ /dev/null @@ -1,33 +0,0 @@ -package com.baeldung.customerservice; - -import com.baeldung.orderservice.client.OrderClient; -import com.baeldung.orderservice.client.OrderDTO; -import com.baeldung.orderservice.client.OrderResponse; -import org.junit.Assert; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; - -@RunWith(SpringJUnit4ClassRunner.class) -@SpringBootTest(classes = CustomerApplication.class) -public class CustomerServiceUnitTest { - - @Autowired - private OrderClient orderClient; - - @Test - public void testAddOrderSuccess(){ - - - OrderDTO dto = new OrderDTO(2,"A152"); - - OrderResponse response = orderClient.order(dto); - - Assert.assertNotNull("Order Id not generated", response.getOrderId()); - Assert.assertEquals("A152", response.getProductId()); - Assert.assertEquals("CREATED", response.getStatus()); - } - -}