From f6d4674ec847a41f4fbb2dfd5b3e9e6830a35743 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20Wo=C5=BAniak?= Date: Thu, 3 Sep 2020 16:59:27 +0200 Subject: [PATCH] Inny error, zmiana lokalizacji pliku MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Marcin Woźniak --- .../{configutils => }/ConfiguratorTest.java | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) rename buisnesslogic/src/test/java/com/plannaplan/{configutils => }/ConfiguratorTest.java (58%) diff --git a/buisnesslogic/src/test/java/com/plannaplan/configutils/ConfiguratorTest.java b/buisnesslogic/src/test/java/com/plannaplan/ConfiguratorTest.java similarity index 58% rename from buisnesslogic/src/test/java/com/plannaplan/configutils/ConfiguratorTest.java rename to buisnesslogic/src/test/java/com/plannaplan/ConfiguratorTest.java index 446c2d8..66edbef 100644 --- a/buisnesslogic/src/test/java/com/plannaplan/configutils/ConfiguratorTest.java +++ b/buisnesslogic/src/test/java/com/plannaplan/ConfiguratorTest.java @@ -1,31 +1,32 @@ -package com.plannaplan.configutils; +package com.plannaplan; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.boot.test.context.SpringBootTest.WebEnvironment; -import org.springframework.boot.test.web.client.TestRestTemplate; -import org.springframework.boot.web.server.LocalServerPort; +import org.springframework.test.context.junit4.SpringRunner; import static org.assertj.core.api.Assertions.assertThat; import static org.junit.Assert.assertTrue; import java.io.InputStream; +import com.plannaplan.App; import com.plannaplan.Configurator; import com.plannaplan.models.ConfigData; import org.junit.Test; +import org.junit.runner.RunWith; +@RunWith(SpringRunner.class) @SpringBootTest public class ConfiguratorTest { - + @Autowired private Configurator restTemplate; @Test public void greetingShouldReturnDefaultMessage() throws Exception { - InputStream inputStream = getClass().getClassLoader().getResourceAsStream("Zajecia.xlsx"); - ConfigData data = new ConfigData(null,null,inputStream); + final InputStream inputStream = getClass().getClassLoader().getResourceAsStream("Zajecia.xlsx"); + final ConfigData data = new ConfigData(null, null, inputStream); this.restTemplate.config(data); assertTrue(true);