-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Piotr Kulasek-Szwed
committed
Nov 17, 2019
1 parent
3febc98
commit f8c1912
Showing
11 changed files
with
62 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
src/mokka/src/main/java/pl/hycom/mokka/AsyncConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package pl.hycom.mokka; | ||
|
||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.scheduling.annotation.EnableAsync; | ||
|
||
/** | ||
* @author Piotr Kulasek-Szwed <[email protected]> | ||
*/ | ||
@Configuration | ||
@EnableAsync | ||
public class AsyncConfiguration { | ||
} |
15 changes: 15 additions & 0 deletions
15
src/mokka/src/main/java/pl/hycom/mokka/RepositoryConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package pl.hycom.mokka; | ||
|
||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.data.envers.repository.support.EnversRevisionRepositoryFactoryBean; | ||
import org.springframework.data.jpa.repository.config.EnableJpaRepositories; | ||
|
||
/** | ||
* @author Piotr Kulasek-Szwed <[email protected]> | ||
*/ | ||
@Configuration | ||
@EnableJpaRepositories( | ||
repositoryFactoryBeanClass = EnversRevisionRepositoryFactoryBean.class | ||
) | ||
public class RepositoryConfiguration { | ||
} |
12 changes: 12 additions & 0 deletions
12
src/mokka/src/main/java/pl/hycom/mokka/SchedulingConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package pl.hycom.mokka; | ||
|
||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.scheduling.annotation.EnableScheduling; | ||
|
||
/** | ||
* @author Piotr Kulasek-Szwed <[email protected]> | ||
*/ | ||
@Configuration | ||
@EnableScheduling | ||
public class SchedulingConfiguration { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,16 +3,16 @@ | |
import org.junit.jupiter.api.extension.ExtendWith; | ||
import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase; | ||
import org.springframework.boot.test.context.SpringBootTest; | ||
import org.springframework.test.context.ActiveProfiles; | ||
import org.springframework.test.context.TestPropertySource; | ||
import org.springframework.test.context.junit.jupiter.SpringExtension; | ||
|
||
/** | ||
* @author Mariusz Krysztofowicz ([email protected]) | ||
*/ | ||
@ExtendWith(SpringExtension.class) | ||
@SpringBootTest(classes = Application.class) | ||
@AutoConfigureTestDatabase | ||
@TestPropertySource(locations = "classpath:test.properties") | ||
@ActiveProfiles("test") | ||
public abstract class AbstractTest { | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,10 @@ | |
import org.junit.jupiter.api.Disabled; | ||
import org.junit.jupiter.api.Test; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.boot.test.autoconfigure.web.client.RestClientTest; | ||
import org.springframework.http.MediaType; | ||
import org.springframework.test.context.ActiveProfiles; | ||
import org.springframework.test.context.TestPropertySource; | ||
import org.springframework.test.web.client.MockRestServiceServer; | ||
import pl.hycom.mokka.service.payment.DefaultPaymentStatusService; | ||
import pl.hycom.mokka.service.payment.pojo.BlueMediaPayment; | ||
|
@@ -16,18 +19,19 @@ | |
/** | ||
* @author Mariusz Krysztofowicz ([email protected]) | ||
*/ | ||
@Disabled | ||
@RestClientTest(DefaultPaymentStatusService.class) | ||
@ActiveProfiles("test") | ||
public class DefaultPaymentStatusServiceTest{ | ||
|
||
@Autowired | ||
private DefaultPaymentStatusService defaultPaymentStatusService; | ||
|
||
@Autowired | ||
private MockRestServiceServer server; | ||
|
||
@BeforeEach | ||
public void init() { | ||
defaultPaymentStatusService = new DefaultPaymentStatusService();//new DefaultHashGenerator()); | ||
this.server.expect(requestTo("/soap/webservice-http/payment")) | ||
this.server.expect(requestTo("http://localhost:48080/soap/webservice-http/payment")) | ||
.andRespond(withSuccess("OK", MediaType.TEXT_PLAIN)); | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
package pl.hycom.mokka.ui.payment; | ||
|
||
import com.github.tomakehurst.wiremock.junit.WireMockRule; | ||
import org.junit.jupiter.api.Assertions; | ||
import org.junit.jupiter.api.BeforeEach; | ||
import org.junit.jupiter.api.Disabled; | ||
|
@@ -12,7 +11,6 @@ | |
|
||
import javax.annotation.Resource; | ||
|
||
import static com.github.tomakehurst.wiremock.client.WireMock.*; | ||
|
||
/** | ||
* @author Jakub Muras <[email protected]> | ||
|
File renamed without changes.