shopServiceTest测试的时候,看懂是什么错

来源:4-3 Thumbnailator图片处理和封装Util

慕虎8165634

2018-12-01

shopServiceTest的时候
十二月 01, 2018 2:41:49 下午 org.springframework.test.context.support.DefaultTestContextBootstrapper getDefaultTestExecutionListenerClassNames
信息: Loaded default TestExecutionListener class names from location [META-INF/spring.factories]: [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]
十二月 01, 2018 2:41:49 下午 org.springframework.test.context.support.DefaultTestContextBootstrapper getTestExecutionListeners
信息: Using TestExecutionListeners: [org.springframework.test.context.web.ServletTestExecutionListener@3f2a3a5, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener@4cb2c100, org.springframework.test.context.support.DependencyInjectionTestExecutionListener@6fb554cc, org.springframework.test.context.support.DirtiesContextTestExecutionListener@614c5515, org.springframework.test.context.transaction.TransactionalTestExecutionListener@77b52d12, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener@2d554825]
十二月 01, 2018 2:41:49 下午 org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions
信息: Loading XML bean definitions from class path resource [spring/spring-dao.xml]
十二月 01, 2018 2:41:50 下午 org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions
信息: Loading XML bean definitions from class path resource [spring/spring-service.xml]
十二月 01, 2018 2:41:50 下午 org.springframework.context.support.GenericApplicationContext prepareRefresh
信息: Refreshing org.springframework.context.support.GenericApplicationContext@4f933fd1: startup date [Sat Dec 01 14:41:50 CST 2018]; root of context hierarchy
十二月 01, 2018 2:41:51 下午 com.mchange.v2.log.MLog
信息: MLog clients using java 1.4+ standard logging.
十二月 01, 2018 2:41:52 下午 com.mchange.v2.c3p0.C3P0Registry banner
信息: Initializing c3p0-0.9.1.2 [built 21-May-2007 15:04:56; debug? true; trace: 10]
十二月 01, 2018 2:41:54 下午 com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource getPoolManager
信息: Initializing c3p0 pool… com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 2, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 10000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge9er9zszua8l16xxqja|16d04d3d, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge9er9zszua8l16xxqja|16d04d3d, idleConnectionTestPeriod -> 0, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost:3306/o2o?useUnicode=true&characterEncoding=utf8, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 0, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 30, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 10, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> null, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]
2018-12-01 14:41:55.185 [main] DEBUG com.imooc.o2o.dao.ShopDao.insertShop - ==> Preparing: insert into tb_shop (shop_id,shop_img,shop_name,shop_desc,phone,shop_addr,advice,priority, enable_status,area_id,shop_category_id,Owner_id,create_time,last_edit_time) values( ?,?,?,?,?,?,?,?, ?,?,?,?,?,? )
2018-12-01 14:41:55.309 [main] DEBUG com.imooc.o2o.dao.ShopDao.insertShop - > Parameters: null, null, 奶茶小哥1(String), test1(String), test1(String), test1(String), 审核中(String), 1(Integer), 0(Integer), 1(Integer), 1(Long), 1(Long), 2018-12-01 14:41:55.088(Timestamp), 2018-12-01 14:41:55.088(Timestamp)
2018-12-01 14:41:55.407 [main] DEBUG com.imooc.o2o.dao.ShopDao.insertShop - < Updates: 1
十二月 01, 2018 2:41:55 下午 org.springframework.context.support.GenericApplicationContext doClose
信息: Closing org.springframework.context.support.GenericApplicationContext@4f933fd1: startup date [Sat Dec 01 14:41:50 CST 2018]; root of context hierarchy

写回答

1回答

翔仔

2018-12-01

同学好,光凭这些信息没办法帮你具体定位,需要你提供ut有个error trace的信息,那边才是报错的原因。同时同学可以设置断点,调试一下,看看错在哪里,一般都会错在generateThumbnail这个方法里

0
0

Java双版本(SSM到SpringBoot)校园商铺全栈开发

SSM商铺V1.0,解决毕设痛点;SpringBoot商铺V2.0,满足工作刚需

5127 学习 · 8148 问题

查看课程