Sto studiando questa webapp realizzata con MyBatis:
https://github.com/Apress/beg-spring-boot-2/tree/master/chapter-06/springboot-mybatis-demo
Passano tutti i 3 test se uso il file .xml, sia su H2 che MySQL 8.0.21 installato localmente.
Con MySQL passano solo 2 test se uso l'interfaccia con le annotazioni in sostituzione del file .xml (
createUser non passa).
Con H2 passano tutti i 3 test se uso l'interfaccia con le annotazioni in sostituzione del file .xml.
IntelliJ mi segna un errore su:
@Autowired private UserMapper userMapper;
@Autowired private UserAnnotationMapper userMapper;
Ovviamente non li uso in modo simultaneo, aggiungo "//" prima di ogni avvio sul codice che non mi serve.
Questa è la classe test:
package com.apress.demo;
import com.apress.demo.domain.User;
import com.apress.demo.mappers.*;
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.SpringRunner;
import java.util.List;
import static org.junit.Assert.*;
/**
* @author Siva
*
*/
@RunWith(SpringRunner.class)
@SpringBootTest//(classes=SpringbootMyBatisDemoApplication.class)
public class SpringbootMyBatisDemoApplicationTests
{
@Autowired private UserMapper userMapper;
//@Autowired private UserAnnotationMapper userMapper;
@Test
public void findAllUsers() {
List<User> users = userMapper.findAllUsers();
assertNotNull(users);
assertTrue(!users.isEmpty());
}
@Test
public void findUserById() {
User user = userMapper.findUserById(1);
assertNotNull(user);
}
@Test
public void createUser() {
User user = new User(0, "george", "george@gmail.com");
userMapper.insertUser(user);
User newUser = userMapper.findUserById(user.getId());
assertEquals("george", newUser.getName());
assertEquals("george@gmail.com", newUser.getEmail());
}
}
Questo invece il Mapper che da problemi:
/**
*
*/
package com.apress.demo.mappers;
import java.util.List;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectKey;
import com.apress.demo.domain.User;
/**
* @author Siva
*
*/
public interface UserAnnotationMapper
{
@Insert("insert into users(name,email) values(#{name},#{email})")
@SelectKey(statement="call identity()", keyProperty="id", before=false, resultType=Integer.class)
void insertUser(User user);
@Select("select id, name, email from users WHERE id=#{id}")
User findUserById(Integer id);
@Select("select id, name, email from users")
List<User> findAllUsers();
}
Ottengo questo:
"C:\Program Files (x86)\Java\jre1.8.0_261\bin\java.exe" -ea -Didea.test.cyclic.buffer.size=1048576 "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\lib\idea_rt.jar=58891:C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin" -Dfile.encoding=UTF-8 -classpath "C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\lib\idea_rt.jar;C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\plugins\junit\lib\junit5-rt.jar;C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\plugins\junit\lib\junit-rt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\charsets.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\deploy.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\access-bridge-32.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\cldrdata.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\dnsns.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\jaccess.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\jfxrt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\localedata.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\nashorn.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunec.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunjce_provider.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunmscapi.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunpkcs11.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\zipfs.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\javaws.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jce.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jfr.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jfxswt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jsse.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\management-agent.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\plugin.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\resources.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\rt.jar;C:\DATI\IntelliJ\06-springboot-mybatis-demo\target\test-classes;C:\DATI\IntelliJ\06-springboot-mybatis-demo\target\classes;C:\Users\DELL\.m2\repository\org\mybatis\spring\boot\mybatis-spring-boot-starter\1.3.0\mybatis-spring-boot-starter-1.3.0.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-2.0.0.BUILD-20180301.043915-633.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot\2.0.0.BUILD-SNAPSHOT\spring-boot-2.0.0.BUILD-20180301.043920-633.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-context\5.0.4.RELEASE\spring-context-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-aop\5.0.4.RELEASE\spring-aop-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-expression\5.0.4.RELEASE\spring-expression-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-autoconfigure\2.0.0.BUILD-SNAPSHOT\spring-boot-autoconfigure-2.0.0.BUILD-20180301.043806-635.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-logging\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-logging-2.0.0.BUILD-20180301.043903-634.jar;C:\Users\DELL\.m2\repository\ch\qos\logback\logback-classic\1.2.3\logback-classic-1.2.3.jar;C:\Users\DELL\.m2\repository\ch\qos\logback\logback-core\1.2.3\logback-core-1.2.3.jar;C:\Users\DELL\.m2\repository\org\apache\logging\log4j\log4j-to-slf4j\2.10.0\log4j-to-slf4j-2.10.0.jar;C:\Users\DELL\.m2\repository\org\apache\logging\log4j\log4j-api\2.10.0\log4j-api-2.10.0.jar;C:\Users\DELL\.m2\repository\org\slf4j\jul-to-slf4j\1.7.25\jul-to-slf4j-1.7.25.jar;C:\Users\DELL\.m2\repository\javax\annotation\javax.annotation-api\1.3.2\javax.annotation-api-1.3.2.jar;C:\Users\DELL\.m2\repository\org\yaml\snakeyaml\1.19\snakeyaml-1.19.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-jdbc\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-jdbc-2.0.0.BUILD-20180301.043858-634.jar;C:\Users\DELL\.m2\repository\com\zaxxer\HikariCP\2.7.8\HikariCP-2.7.8.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-jdbc\5.0.4.RELEASE\spring-jdbc-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-beans\5.0.4.RELEASE\spring-beans-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-tx\5.0.4.RELEASE\spring-tx-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\mybatis\spring\boot\mybatis-spring-boot-autoconfigure\1.3.0\mybatis-spring-boot-autoconfigure-1.3.0.jar;C:\Users\DELL\.m2\repository\org\mybatis\mybatis\3.4.4\mybatis-3.4.4.jar;C:\Users\DELL\.m2\repository\org\mybatis\mybatis-spring\1.3.1\mybatis-spring-1.3.1.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-test\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-test-2.0.0.BUILD-20180301.043908-634.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-test\2.0.0.BUILD-SNAPSHOT\spring-boot-test-2.0.0.BUILD-20180301.043918-633.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-test-autoconfigure\2.0.0.BUILD-SNAPSHOT\spring-boot-test-autoconfigure-2.0.0.BUILD-20180301.043917-633.jar;C:\Users\DELL\.m2\repository\com\jayway\jsonpath\json-path\2.4.0\json-path-2.4.0.jar;C:\Users\DELL\.m2\repository\net\minidev\json-smart\2.3\json-smart-2.3.jar;C:\Users\DELL\.m2\repository\net\minidev\accessors-smart\1.2\accessors-smart-1.2.jar;C:\Users\DELL\.m2\repository\org\ow2\asm\asm\5.0.4\asm-5.0.4.jar;C:\Users\DELL\.m2\repository\org\slf4j\slf4j-api\1.7.25\slf4j-api-1.7.25.jar;C:\Users\DELL\.m2\repository\junit\junit\4.12\junit-4.12.jar;C:\Users\DELL\.m2\repository\org\assertj\assertj-core\3.9.1\assertj-core-3.9.1.jar;C:\Users\DELL\.m2\repository\org\mockito\mockito-core\2.15.0\mockito-core-2.15.0.jar;C:\Users\DELL\.m2\repository\net\bytebuddy\byte-buddy\1.7.10\byte-buddy-1.7.10.jar;C:\Users\DELL\.m2\repository\net\bytebuddy\byte-buddy-agent\1.7.10\byte-buddy-agent-1.7.10.jar;C:\Users\DELL\.m2\repository\org\objenesis\objenesis\2.6\objenesis-2.6.jar;C:\Users\DELL\.m2\repository\org\hamcrest\hamcrest-core\1.3\hamcrest-core-1.3.jar;C:\Users\DELL\.m2\repository\org\hamcrest\hamcrest-library\1.3\hamcrest-library-1.3.jar;C:\Users\DELL\.m2\repository\org\skyscreamer\jsonassert\1.5.0\jsonassert-1.5.0.jar;C:\Users\DELL\.m2\repository\com\vaadin\external\google\android-json\0.0.20131108.vaadin1\android-json-0.0.20131108.vaadin1.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-core\5.0.4.RELEASE\spring-core-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-jcl\5.0.4.RELEASE\spring-jcl-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-test\5.0.4.RELEASE\spring-test-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\xmlunit\xmlunit-core\2.5.1\xmlunit-core-2.5.1.jar;C:\Users\DELL\.m2\repository\mysql\mysql-connector-java\8.0.21\mysql-connector-java-8.0.21.jar;C:\Users\DELL\.m2\repository\com\google\protobuf\protobuf-java\3.11.4\protobuf-java-3.11.4.jar;C:\Users\DELL\.m2\repository\com\h2database\h2\1.4.196\h2-1.4.196.jar" com.intellij.rt.junit.JUnitStarter -ideVersion5 @w@C:\Users\DELL\AppData\Local\Temp\idea_working_dirs_junit.tmp @C:\Users\DELL\AppData\Local\Temp\idea_junit.tmp -socket58890
22:30:59.337 [main] DEBUG org.springframework.test.context.junit4.SpringJUnit4ClassRunner - SpringJUnit4ClassRunner constructor called with [class com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.348 [main] DEBUG org.springframework.test.context.BootstrapUtils - Instantiating CacheAwareContextLoaderDelegate from class [org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate]
22:30:59.358 [main] DEBUG org.springframework.test.context.BootstrapUtils - Instantiating BootstrapContext using constructor [public org.springframework.test.context.support.DefaultBootstrapContext(java.lang.Class,org.springframework.test.context.CacheAwareContextLoaderDelegate)]
22:30:59.376 [main] DEBUG org.springframework.test.context.BootstrapUtils - Instantiating TestContextBootstrapper for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests] from class [org.springframework.boot.test.context.SpringBootTestContextBootstrapper]
22:30:59.397 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Neither @ContextConfiguration nor @ContextHierarchy found for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests], using SpringBootContextLoader
22:30:59.403 [main] DEBUG org.springframework.test.context.support.AbstractContextLoader - Did not detect default resource location for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]: class path resource [com/apress/demo/SpringbootMyBatisDemoApplicationTests-context.xml] does not exist
22:30:59.403 [main] DEBUG org.springframework.test.context.support.AbstractContextLoader - Did not detect default resource location for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]: class path resource [com/apress/demo/SpringbootMyBatisDemoApplicationTestsContext.groovy] does not exist
22:30:59.403 [main] INFO org.springframework.test.context.support.AbstractContextLoader - Could not detect default resource locations for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]: no resource found for suffixes {-context.xml, Context.groovy}.
22:30:59.459 [main] DEBUG org.springframework.test.context.support.ActiveProfilesUtils - Could not find an 'annotation declaring class' for annotation type [org.springframework.test.context.ActiveProfiles] and class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.695 [main] DEBUG org.springframework.boot.test.context.SpringBootTestContextBootstrapper - @TestExecutionListeners is not present for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]: using defaults.
22:30:59.696 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Loaded default TestExecutionListener class names from location [META-INF/spring.factories]: [org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener, org.springframework.test.context.web.ServletTestExecutionListener, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener, org.springframework.test.context.support.DependencyInjectionTestExecutionListener, org.springframework.test.context.support.DirtiesContextTestExecutionListener, org.springframework.test.context.transaction.TransactionalTestExecutionListener, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener]
22:30:59.719 [main] DEBUG org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Skipping candidate TestExecutionListener [org.springframework.test.context.web.ServletTestExecutionListener] due to a missing dependency. Specify custom listener classes or make the default listener classes and their required dependencies available. Offending class: [javax/servlet/ServletContext]
22:30:59.756 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper - Using TestExecutionListeners: [org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener@b66d36, org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener@23e5ee, org.springframework.boot.test.autoconfigure.SpringBootDependencyInjectionTestExecutionListener@1ef2d72, org.springframework.test.context.support.DirtiesContextTestExecutionListener@1b2283a, org.springframework.test.context.transaction.TransactionalTestExecutionListener@a637e7, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener@1e7aac8, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener@1119efb, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener@19a969b, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener@908cc0, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener@73d930, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener@1047d03]
22:30:59.765 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.766 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
ID associato all'utente: 0
2020-08-01 22:31:02.387 INFO 9952 --- [ main] o.s.b.f.xml.XmlBeanDefinitionReader : Loading XML bean definitions from class path resource [org/springframework/jdbc/support/sql-error-codes.xml]
2020-08-01 22:31:02.419 INFO 9952 --- [ main] o.s.jdbc.support.SQLErrorCodesFactory : SQLErrorCodes loaded: [DB2, Derby, H2, HSQL, Informix, MS-SQL, MySQL, Oracle, PostgreSQL, Sybase, Hana]
org.springframework.jdbc.BadSqlGrammarException: Error selecting key or setting result to parameter object. Cause: java.sql.SQLSyntaxErrorException: PROCEDURE test.identity does not exist
; bad SQL grammar []; nested exception is java.sql.SQLSyntaxErrorException: PROCEDURE test.identity does not exist
at org.springframework.jdbc.support.SQLExceptionSubclassTranslator.doTranslate(SQLExceptionSubclassTranslator.java:93)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:72)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:81)
at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:73)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:446)
at com.sun.proxy.$Proxy57.insert(Unknown Source)
at org.mybatis.spring.SqlSessionTemplate.insert(SqlSessionTemplate.java:278)
at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:57)
at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:59)
at com.sun.proxy.$Proxy64.insertUser(Unknown Source)
at com.apress.demo.SpringbootMyBatisDemoApplicationTests.createUser(SpringbootMyBatisDemoApplicationTests.java:65)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:73)
at org.springframework.test.context.junit4.statements.RunAfterTestExecutionCallbacks.evaluate(RunAfterTestExecutionCallbacks.java:83)
at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:251)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:69)
at com.intellij.rt.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:33)
at com.intellij.rt.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:220)
at com.intellij.rt.junit.JUnitStarter.main(JUnitStarter.java:53)
Caused by: java.sql.SQLSyntaxErrorException: PROCEDURE test.identity does not exist
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:120)
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:953)
at com.mysql.cj.jdbc.ClientPreparedStatement.execute(ClientPreparedStatement.java:370)
at com.zaxxer.hikari.pool.ProxyPreparedStatement.execute(ProxyPreparedStatement.java:44)
at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.execute(HikariProxyPreparedStatement.java)
at org.apache.ibatis.executor.statement.PreparedStatementHandler.query(PreparedStatementHandler.java:63)
at org.apache.ibatis.executor.statement.RoutingStatementHandler.query(RoutingStatementHandler.java:79)
at org.apache.ibatis.executor.SimpleExecutor.doQuery(SimpleExecutor.java:63)
at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:324)
at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:156)
at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:109)
at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:83)
at org.apache.ibatis.executor.keygen.SelectKeyGenerator.processGeneratedKeys(SelectKeyGenerator.java:68)
at org.apache.ibatis.executor.keygen.SelectKeyGenerator.processAfter(SelectKeyGenerator.java:54)
at org.apache.ibatis.executor.statement.PreparedStatementHandler.update(PreparedStatementHandler.java:50)
at org.apache.ibatis.executor.statement.RoutingStatementHandler.update(RoutingStatementHandler.java:74)
at org.apache.ibatis.executor.SimpleExecutor.doUpdate(SimpleExecutor.java:50)
at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117)
at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76)
at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:198)
at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:185)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:433)
... 44 more
22:30:59.781 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.781 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.786 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.786 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.787 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.787 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.787 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.787 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.793 [main] DEBUG org.springframework.test.context.support.AbstractDirtiesContextTestExecutionListener - Before test class: context [DefaultTestContext@1c43bd9 testClass = SpringbootMyBatisDemoApplicationTests, testInstance = [null], testMethod = [null], testException = [null], mergedContextConfiguration = [MergedContextConfiguration@174bf60 testClass = SpringbootMyBatisDemoApplicationTests, locations = '{}', classes = '{class com.apress.demo.SpringbootMyBatisDemoApplication, class com.apress.demo.SpringbootMyBatisDemoApplication}', contextInitializerClasses = '[]', activeProfiles = '{}', propertySourceLocations = '{}', propertySourceProperties = '{org.springframework.boot.test.context.SpringBootTestContextBootstrapper=true}', contextCustomizers = set[org.springframework.boot.test.context.filter.ExcludeFilterContextCustomizer@6d1014, org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer@1554b06, org.springframework.boot.test.mock.mockito.MockitoContextCustomizer@0, org.springframework.boot.test.web.client.TestRestTemplateContextCustomizer@cdbdf5, org.springframework.boot.test.autoconfigure.properties.PropertyMappingContextCustomizer@0, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverContextCustomizerFactory$Customizer@8931cf], contextLoader = 'org.springframework.boot.test.context.SpringBootContextLoader', parent = [null]], attributes = map[[empty]]], class annotated with @DirtiesContext [false] with mode [null].
22:30:59.793 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved @ProfileValueSourceConfiguration [null] for test class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.793 [main] DEBUG org.springframework.test.annotation.ProfileValueUtils - Retrieved ProfileValueSource type [class org.springframework.test.annotation.SystemProfileValueSource] for class [com.apress.demo.SpringbootMyBatisDemoApplicationTests]
22:30:59.799 [main] DEBUG org.springframework.test.context.support.DependencyInjectionTestExecutionListener - Performing dependency injection for test context [[DefaultTestContext@1c43bd9 testClass = SpringbootMyBatisDemoApplicationTests, testInstance = com.apress.demo.SpringbootMyBatisDemoApplicationTests@122c3c3, testMethod = [null], testException = [null], mergedContextConfiguration = [MergedContextConfiguration@174bf60 testClass = SpringbootMyBatisDemoApplicationTests, locations = '{}', classes = '{class com.apress.demo.SpringbootMyBatisDemoApplication, class com.apress.demo.SpringbootMyBatisDemoApplication}', contextInitializerClasses = '[]', activeProfiles = '{}', propertySourceLocations = '{}', propertySourceProperties = '{org.springframework.boot.test.context.SpringBootTestContextBootstrapper=true}', contextCustomizers = set[org.springframework.boot.test.context.filter.ExcludeFilterContextCustomizer@6d1014, org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer@1554b06, org.springframework.boot.test.mock.mockito.MockitoContextCustomizer@0, org.springframework.boot.test.web.client.TestRestTemplateContextCustomizer@cdbdf5, org.springframework.boot.test.autoconfigure.properties.PropertyMappingContextCustomizer@0, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverContextCustomizerFactory$Customizer@8931cf], contextLoader = 'org.springframework.boot.test.context.SpringBootContextLoader', parent = [null]], attributes = map[[empty]]]].
22:30:59.847 [main] DEBUG org.springframework.core.env.StandardEnvironment - Adding PropertySource 'systemProperties' with lowest search precedence
22:30:59.848 [main] DEBUG org.springframework.core.env.StandardEnvironment - Adding PropertySource 'systemEnvironment' with lowest search precedence
22:30:59.850 [main] DEBUG org.springframework.core.env.StandardEnvironment - Initialized StandardEnvironment with PropertySources [MapPropertySource@2442716 {name='systemProperties', properties={java.runtime.name=Java(TM) SE Runtime Environment, sun.boot.library.path=C:\Program Files (x86)\Java\jre1.8.0_261\bin, java.vm.version=25.261-b12, java.vm.vendor=Oracle Corporation, java.vendor.url=http://java.oracle.com/, path.separator=;, java.vm.name=Java HotSpot(TM) Client VM, file.encoding.pkg=sun.io, user.country=IT, user.script=, sun.java.launcher=SUN_STANDARD, sun.os.patch.level=, java.vm.specification.name=Java Virtual Machine Specification, user.dir=C:\DATI\IntelliJ\06-springboot-mybatis-demo, java.runtime.version=1.8.0_261-b12, java.awt.graphicsenv=sun.awt.Win32GraphicsEnvironment, java.endorsed.dirs=C:\Program Files (x86)\Java\jre1.8.0_261\lib\endorsed, os.arch=x86, java.io.tmpdir=C:\Users\DELL\AppData\Local\Temp\, line.separator=
, java.vm.specification.vendor=Oracle Corporation, user.variant=, os.name=Windows 10, sun.jnu.encoding=Cp1252, java.library.path=C:\Program Files (x86)\Java\jre1.8.0_261\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\MySQL\MySQL Shell 8.0\bin\;C:\Users\DELL\AppData\Local\Microsoft\WindowsApps;;., java.specification.name=Java Platform API Specification, java.class.version=52.0, sun.management.compiler=HotSpot Client Compiler, os.version=10.0, user.home=C:\Users\DELL, user.timezone=Europe/Berlin, java.awt.printerjob=sun.awt.windows.WPrinterJob, file.encoding=UTF-8, java.specification.version=1.8, java.class.path=C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\lib\idea_rt.jar;C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\plugins\junit\lib\junit5-rt.jar;C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\plugins\junit\lib\junit-rt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\charsets.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\deploy.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\access-bridge-32.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\cldrdata.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\dnsns.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\jaccess.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\jfxrt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\localedata.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\nashorn.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunec.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunjce_provider.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunmscapi.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\sunpkcs11.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext\zipfs.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\javaws.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jce.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jfr.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jfxswt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jsse.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\management-agent.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\plugin.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\resources.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\rt.jar;C:\DATI\IntelliJ\06-springboot-mybatis-demo\target\test-classes;C:\DATI\IntelliJ\06-springboot-mybatis-demo\target\classes;C:\Users\DELL\.m2\repository\org\mybatis\spring\boot\mybatis-spring-boot-starter\1.3.0\mybatis-spring-boot-starter-1.3.0.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-2.0.0.BUILD-20180301.043915-633.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot\2.0.0.BUILD-SNAPSHOT\spring-boot-2.0.0.BUILD-20180301.043920-633.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-context\5.0.4.RELEASE\spring-context-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-aop\5.0.4.RELEASE\spring-aop-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-expression\5.0.4.RELEASE\spring-expression-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-autoconfigure\2.0.0.BUILD-SNAPSHOT\spring-boot-autoconfigure-2.0.0.BUILD-20180301.043806-635.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-logging\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-logging-2.0.0.BUILD-20180301.043903-634.jar;C:\Users\DELL\.m2\repository\ch\qos\logback\logback-classic\1.2.3\logback-classic-1.2.3.jar;C:\Users\DELL\.m2\repository\ch\qos\logback\logback-core\1.2.3\logback-core-1.2.3.jar;C:\Users\DELL\.m2\repository\org\apache\logging\log4j\log4j-to-slf4j\2.10.0\log4j-to-slf4j-2.10.0.jar;C:\Users\DELL\.m2\repository\org\apache\logging\log4j\log4j-api\2.10.0\log4j-api-2.10.0.jar;C:\Users\DELL\.m2\repository\org\slf4j\jul-to-slf4j\1.7.25\jul-to-slf4j-1.7.25.jar;C:\Users\DELL\.m2\repository\javax\annotation\javax.annotation-api\1.3.2\javax.annotation-api-1.3.2.jar;C:\Users\DELL\.m2\repository\org\yaml\snakeyaml\1.19\snakeyaml-1.19.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-jdbc\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-jdbc-2.0.0.BUILD-20180301.043858-634.jar;C:\Users\DELL\.m2\repository\com\zaxxer\HikariCP\2.7.8\HikariCP-2.7.8.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-jdbc\5.0.4.RELEASE\spring-jdbc-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-beans\5.0.4.RELEASE\spring-beans-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-tx\5.0.4.RELEASE\spring-tx-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\mybatis\spring\boot\mybatis-spring-boot-autoconfigure\1.3.0\mybatis-spring-boot-autoconfigure-1.3.0.jar;C:\Users\DELL\.m2\repository\org\mybatis\mybatis\3.4.4\mybatis-3.4.4.jar;C:\Users\DELL\.m2\repository\org\mybatis\mybatis-spring\1.3.1\mybatis-spring-1.3.1.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-starter-test\2.0.0.BUILD-SNAPSHOT\spring-boot-starter-test-2.0.0.BUILD-20180301.043908-634.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-test\2.0.0.BUILD-SNAPSHOT\spring-boot-test-2.0.0.BUILD-20180301.043918-633.jar;C:\Users\DELL\.m2\repository\org\springframework\boot\spring-boot-test-autoconfigure\2.0.0.BUILD-SNAPSHOT\spring-boot-test-autoconfigure-2.0.0.BUILD-20180301.043917-633.jar;C:\Users\DELL\.m2\repository\com\jayway\jsonpath\json-path\2.4.0\json-path-2.4.0.jar;C:\Users\DELL\.m2\repository\net\minidev\json-smart\2.3\json-smart-2.3.jar;C:\Users\DELL\.m2\repository\net\minidev\accessors-smart\1.2\accessors-smart-1.2.jar;C:\Users\DELL\.m2\repository\org\ow2\asm\asm\5.0.4\asm-5.0.4.jar;C:\Users\DELL\.m2\repository\org\slf4j\slf4j-api\1.7.25\slf4j-api-1.7.25.jar;C:\Users\DELL\.m2\repository\junit\junit\4.12\junit-4.12.jar;C:\Users\DELL\.m2\repository\org\assertj\assertj-core\3.9.1\assertj-core-3.9.1.jar;C:\Users\DELL\.m2\repository\org\mockito\mockito-core\2.15.0\mockito-core-2.15.0.jar;C:\Users\DELL\.m2\repository\net\bytebuddy\byte-buddy\1.7.10\byte-buddy-1.7.10.jar;C:\Users\DELL\.m2\repository\net\bytebuddy\byte-buddy-agent\1.7.10\byte-buddy-agent-1.7.10.jar;C:\Users\DELL\.m2\repository\org\objenesis\objenesis\2.6\objenesis-2.6.jar;C:\Users\DELL\.m2\repository\org\hamcrest\hamcrest-core\1.3\hamcrest-core-1.3.jar;C:\Users\DELL\.m2\repository\org\hamcrest\hamcrest-library\1.3\hamcrest-library-1.3.jar;C:\Users\DELL\.m2\repository\org\skyscreamer\jsonassert\1.5.0\jsonassert-1.5.0.jar;C:\Users\DELL\.m2\repository\com\vaadin\external\google\android-json\0.0.20131108.vaadin1\android-json-0.0.20131108.vaadin1.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-core\5.0.4.RELEASE\spring-core-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-jcl\5.0.4.RELEASE\spring-jcl-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\springframework\spring-test\5.0.4.RELEASE\spring-test-5.0.4.RELEASE.jar;C:\Users\DELL\.m2\repository\org\xmlunit\xmlunit-core\2.5.1\xmlunit-core-2.5.1.jar;C:\Users\DELL\.m2\repository\mysql\mysql-connector-java\8.0.21\mysql-connector-java-8.0.21.jar;C:\Users\DELL\.m2\repository\com\google\protobuf\protobuf-java\3.11.4\protobuf-java-3.11.4.jar;C:\Users\DELL\.m2\repository\com\h2database\h2\1.4.196\h2-1.4.196.jar;C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\lib\idea_rt.jar, user.name=DELL, java.vm.specification.version=1.8, sun.java.command=com.intellij.rt.junit.JUnitStarter -ideVersion5 @w@C:\Users\DELL\AppData\Local\Temp\idea_working_dirs_junit.tmp @C:\Users\DELL\AppData\Local\Temp\idea_junit.tmp -socket58890, java.home=C:\Program Files (x86)\Java\jre1.8.0_261, sun.arch.data.model=32, user.language=it, java.specification.vendor=Oracle Corporation, awt.toolkit=sun.awt.windows.WToolkit, java.vm.info=mixed mode, java.version=1.8.0_261, java.ext.dirs=C:\Program Files (x86)\Java\jre1.8.0_261\lib\ext;C:\WINDOWS\Sun\Java\lib\ext, sun.boot.class.path=C:\Program Files (x86)\Java\jre1.8.0_261\lib\resources.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\rt.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\sunrsasign.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jsse.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jce.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\charsets.jar;C:\Program Files (x86)\Java\jre1.8.0_261\lib\jfr.jar;C:\Program Files (x86)\Java\jre1.8.0_261\classes, java.vendor=Oracle Corporation, file.separator=\, java.vendor.url.bug=http://bugreport.sun.com/bugreport/, idea.test.cyclic.buffer.size=1048576, sun.io.unicode.encoding=UnicodeLittle, sun.cpu.endian=little, sun.desktop=windows, sun.cpu.isalist=pentium_pro+mmx pentium_pro pentium+mmx pentium i486 i386 i86}}, SystemEnvironmentPropertySource@6221807 {name='systemEnvironment', properties={USERDOMAIN_ROAMINGPROFILE=DESKTOP-N74IH9B, LOCALAPPDATA=C:\Users\DELL\AppData\Local, PROCESSOR_LEVEL=6, USERDOMAIN=DESKTOP-N74IH9B, LOGONSERVER=\\DESKTOP-N74IH9B, SESSIONNAME=Console, ALLUSERSPROFILE=C:\ProgramData, PROCESSOR_ARCHITECTURE=x86, PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules, SystemDrive=C:, OneDrive=C:\Users\DELL\OneDrive, APPDATA=C:\Users\DELL\AppData\Roaming, USERNAME=DELL, ProgramFiles(x86)=C:\Program Files (x86), CommonProgramFiles=C:\Program Files (x86)\Common Files, Path=C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\MySQL\MySQL Shell 8.0\bin\;C:\Users\DELL\AppData\Local\Microsoft\WindowsApps;, PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC, DriverData=C:\Windows\System32\Drivers\DriverData, OS=Windows_NT, PROCESSOR_ARCHITEW6432=AMD64, COMPUTERNAME=DESKTOP-N74IH9B, PROCESSOR_REVISION=8e0c, CommonProgramW6432=C:\Program Files\Common Files, ComSpec=C:\WINDOWS\system32\cmd.exe, ProgramData=C:\ProgramData, ProgramW6432=C:\Program Files, HOMEPATH=\Users\DELL, SystemRoot=C:\WINDOWS, TEMP=C:\Users\DELL\AppData\Local\Temp, HOMEDRIVE=C:, PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 142 Stepping 12, GenuineIntel, USERPROFILE=C:\Users\DELL, TMP=C:\Users\DELL\AppData\Local\Temp, CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files, ProgramFiles=C:\Program Files (x86), PUBLIC=C:\Users\Public, NUMBER_OF_PROCESSORS=4, windir=C:\WINDOWS, =::=::\, IDEA_INITIAL_DIRECTORY=C:\WINDOWS\System32}}]
22:30:59.853 [main] DEBUG org.springframework.test.context.support.TestPropertySourceUtils - Adding inlined properties to environment: {spring.jmx.enabled=false, org.springframework.boot.test.context.SpringBootTestContextBootstrapper=true, server.port=-1}
22:30:59.854 [main] DEBUG org.springframework.core.env.StandardEnvironment - Adding PropertySource 'Inlined Test Properties' with highest search precedence
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v2.0.0.BUILD-SNAPSHOT)
2020-08-01 22:31:00.397 INFO 9952 --- [ main] .d.SpringbootMyBatisDemoApplicationTests : Starting SpringbootMyBatisDemoApplicationTests on DESKTOP-N74IH9B with PID 9952 (started by DELL in C:\DATI\IntelliJ\06-springboot-mybatis-demo)
2020-08-01 22:31:00.398 INFO 9952 --- [ main] .d.SpringbootMyBatisDemoApplicationTests : The following profiles are active: prod
2020-08-01 22:31:00.419 INFO 9952 --- [ main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@12abca6: startup date [Sat Aug 01 22:31:00 CEST 2020]; root of context hierarchy
2020-08-01 22:31:01.041 INFO 9952 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Starting...
2020-08-01 22:31:01.179 INFO 9952 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Start completed.
2020-08-01 22:31:01.183 INFO 9952 --- [ main] o.s.jdbc.datasource.init.ScriptUtils : Executing SQL script from URL [file:/C:/DATI/IntelliJ/06-springboot-mybatis-demo/target/classes/schema.sql]
2020-08-01 22:31:01.242 INFO 9952 --- [ main] o.s.jdbc.datasource.init.ScriptUtils : Executed SQL script from URL [file:/C:/DATI/IntelliJ/06-springboot-mybatis-demo/target/classes/schema.sql] in 59 ms.
2020-08-01 22:31:01.246 INFO 9952 --- [ main] o.s.jdbc.datasource.init.ScriptUtils : Executing SQL script from URL [file:/C:/DATI/IntelliJ/06-springboot-mybatis-demo/target/classes/data.sql]
2020-08-01 22:31:01.265 INFO 9952 --- [ main] o.s.jdbc.datasource.init.ScriptUtils : Executed SQL script from URL [file:/C:/DATI/IntelliJ/06-springboot-mybatis-demo/target/classes/data.sql] in 19 ms.
2020-08-01 22:31:02.243 INFO 9952 --- [ main] .d.SpringbootMyBatisDemoApplicationTests : Started SpringbootMyBatisDemoApplicationTests in 2.386 seconds (JVM running for 3.516)
2020-08-01 22:31:02.432 INFO 9952 --- [ Thread-2] s.c.a.AnnotationConfigApplicationContext : Closing org.springframework.context.annotation.AnnotationConfigApplicationContext@12abca6: startup date [Sat Aug 01 22:31:00 CEST 2020]; root of context hierarchy
2020-08-01 22:31:02.433 INFO 9952 --- [ Thread-2] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown initiated...
2020-08-01 22:31:02.441 INFO 9952 --- [ Thread-2] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown completed.
Process finished with exit code -1
Perché accade questo?