introducing prod-test environment

This commit is contained in:
Bossanyi Tibor 2020-09-02 14:51:13 +02:00
parent 2ee95d1d43
commit a341f2cdbe
3 changed files with 23 additions and 2 deletions

View File

@ -47,7 +47,7 @@ class ExerciseTypeController ( private val exerciseTypeRepository: ExerciseTypeR
@GetMapping("exercise_type/active")
fun getActiveExerciseType(): List<ExerciseType> {
val list: List<ExerciseType> = exerciseTypeRepository.getActiveExerciseTypes()
logger.info("-- Get Active Exercise Types with Images and Translation -- ")
logger.info("-- Get Active Exercise Types with Images and Translation -- $list")
return list
}

View File

@ -0,0 +1,21 @@
spring.profiles.active=prod
## Spring DATASOURCE (DataSourceAutoConfiguration & DataSourceProperties)
spring.datasource.url = jdbc:mysql://62.171.188.119:33060/aitrainer_test?serverTimezone=CET&useSSL=false&characterEncoding=UTF-8&allowPublicKeyRetrieval=true&allowMultiQueries=true
spring.datasource.username = aitrainer
spring.datasource.password = andio2009
## Hibernate Properties
# The SQL dialect makes Hibernate generate better SQL for the chosen database
spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5InnoDBDialect
logging.config=classpath:logback-spring.xml
logging.file=logs
# if the database structure has been changed, increment this version number
application.version=1.0.5application-prod.properties
jwt.secret=aitrainer

View File

@ -50,7 +50,7 @@ class ExerciseTypeTest {
@Test
fun testInsert(){
logger.info("Add 'Húzodszkodás 2")
val newEx = ExerciseType( 0,"Húzodszkodás 2", " A legtöbb húzodszkodást 24 óra alatt John Ort érte el 7600-al 2016-ban. ", null, null, null ,true)
val newEx = ExerciseType( 0,"Húzodszkodás 2", " A legtöbb húzodszkodást 24 óra alatt John Ort érte el 7600-al 2016-ban. ", null, null, null ,true, false)
val savedEx: ExerciseType = exerciseTypeRepository.save(newEx)
assertEquals(savedEx.name, "Húzodszkodás 2")