Caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getUser' in class org.uncommons.reportng.ReportMetadata threw exception class java.net.UnknownHostException :
Running TestSuite
[TestNG] [WARN] Ignoring duplicate listener : org.uncommons.reportng.HTMLReporter
[TestNG] [WARN] Ignoring duplicate listener : org.uncommons.reportng.JUnitXMLReporter
[INFO ] 2019-04-21 18:26:24,609 method:com.chen.autocases.TestDemo.testcase1(TestDemo.java:10)
testcase1
[TestNG] Reporter org.uncommons.reportng.HTMLReporter@1e7bba3 failed
org.uncommons.reportng.ReportNGException: Failed generating HTML report.
at org.uncommons.reportng.HTMLReporter.generateReport(HTMLReporter.java:122)
at org.testng.TestNG.generateReports(TestNG.java:1097)
at org.testng.TestNG.run(TestNG.java:1022)
at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:170)
at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:84)
at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:92)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray2(ReflectionUtils.java:208)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:156)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:82)
at org.apache.maven.plugin.surefire.InPluginVMSurefireStarter.runSuitesInProcess(InPluginVMSurefireStarter.java:82)
at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:867)
at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:747)
at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:645)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:318)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:153)
at org.jvnet.hudson.maven3.launcher.Maven31Launcher.main(Maven31Launcher.java:132)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:331)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:239)
at jenkins.maven3.agent.Maven31Main.launch(Maven31Main.java:185)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:139)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:70)
at hudson.remoting.UserRequest.perform(UserRequest.java:181)
at hudson.remoting.UserRequest.perform(UserRequest.java:52)
at hudson.remoting.Request$2.run(Request.java:336)
at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getUser' in class org.uncommons.reportng.ReportMetadata threw exception class java.net.UnknownHostException : bogon: bogon: Temporary failure in name resolution
at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:193)
at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:175)
at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:220)
at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:230)
at org.apache.velocity.Template.merge(Template.java:256)
at org.apache.velocity.app.Velocity.mergeTemplate(Velocity.java:449)
at org.uncommons.reportng.AbstractReporter.generateFile(AbstractReporter.java:108)
at org.uncommons.reportng.HTMLReporter.createOverview(HTMLReporter.java:148)
at org.uncommons.reportng.HTMLReporter.generateReport(HTMLReporter.java:111)
... 48 more
Tests run: 2, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 15.332 sec <<< FAILURE! - in TestSuite
testcase1(com.chen.autocases.TestDemo) Time elapsed: 0.01 sec <<< FAILURE!
java.lang.AssertionError: expected [true] but found [false]
解决方法:
[root@bogon secrets]# hostname
bogon
解决方法:
1 执行hostname命令
可以看出 ping 不通我们的hostname 这就是原因所在
2 修改 /etc/sysconfig/network
改成我们的hostname命令下的名字
3 修改 /etc/hosts内容
加上我们的hostname命令下的名字
4 最后执行 /etc/rc.d/init.d/network rest
Caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getUser' in class org.uncommons.reportng.ReportMetadata threw exception class java.net.UnknownHostException :的更多相关文章
- velecity报错:Caused by: org.apache.velocity.exception.ParseErrorException: Lexical error, Encountered: <EOF> after : "\'/order/pay?activity=\" + activityId);\r\n }*/\r\n</script>\r\n#end\r\n" at /a
Caused by: org.apache.velocity.exception.ParseErrorException: Lexical error, Encountered: <EOF> ...
- org.springframework.beans.MethodInvocationException: Property 'cacheManager' threw exception; nested exception is org.apache.shiro.cache.CacheException: net.sf.ehcache.CacheException: Caches cannot be
shiro cache manage配置报错: org.springframework.beans.MethodInvocationException: Property 'cacheManager' ...
- 遇到的错误之"Exception in thread “main“ java.lang.NoClassDefFoundError: org/apache/velocity/context/Context at"
问题 Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/velocity/context/ ...
- ?--Porg.springframework.beans.MethodInvocationException: Property 'username' threw exception; nested exception is java.lang.NullPointerException
使用BoneCP作为连接池,在启动Tomcat报出以下异常: 一月 02, 2016 2:12:17 下午 org.apache.tomcat.util.digester.SetPropertiesR ...
- Caused by: org.apache.ibatis.exceptions.TooManyResultsException: Expected one result (or null) to be returned by selectOne(), but found: 2
异常信息 Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with na ...
- 《Apache Velocity用户指南》官方文档
http://ifeve.com/apache-velocity-dev/ <Apache Velocity用户指南>官方文档 原文链接 译文连接 译者:小村长 校对:方腾飞 Qui ...
- Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'company' in 'class java.lang.String'
Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named ' ...
- Caused by: org.apache.ibatis.binding.BindingException: Parameter 'parameter' not found.解决
Caused by: org.apache.ibatis.binding.BindingException: Parameter 'company' not found. Available para ...
- spring和mybatis整合报错:org.springframework.beans.MethodInvocationException: Property 'dataSource' threw exception; nested exception is java.lang.NoClassDefFoundError
Exception in thread "main" org.springframework.beans.factory.UnsatisfiedDependencyExceptio ...
随机推荐
- 列表 enumerat 解包, 针对索引和元素
dic = [1,2,3,4,5] for a,b in enumerate(dic): print(a,b) # a就是索引 b是元素
- 记一次简单爬虫(豆瓣/dytt)
磕磕绊绊学python一个月,这次到正则表达式终于能写点有趣的东西,在此作个记录: ————————————————————————————————————————————————— 1.爬取豆瓣电影 ...
- webpack打包遇到过的问题
1.打包后html文件打开是空白页面,报错信息如图所示: 解决办法:这里主要是将assetsPublicPath的路径从'/'改为'./'就好了. ('/'表示根目录:'./'表示当前目录) 2.运行 ...
- JSON学习笔记-3
JSON 对象 1.对象语法 JSON 对象使用在大括号({})中书写. 对象可以包含多个 key/value(键/值)对. key 必须是字符串,value 可以是合法的 JSON 数据类型(字符串 ...
- Linux pyenv环境安装
python工作环境管理 pyenv安装: git clone https://github.com/pyenv/pyenv ~/.pyenv echo 'export PYENV_ROOT=&quo ...
- 第六章 函数、谓词、CASE表达式 6-1 各种各样的函数
一.函数的种类 算术函数 字符串函数 日期函数 转换函数 聚合函数 二.算术函数 + - * / 1.ABS——绝对值 ABS(数值) 绝对值 absolute value ,不考虑数值的符号 ...
- Oracle GoldenGate DDL 详细说明 使用手册(较早资料)
一. 概述 DDL 相关的参数包括:DDL.DDLERROR.DDLOPTIONS.DDLSUBST.DDLTABLE.GGSCHEMA. PURGEDDLHISTORY.PURGEMARKERHIS ...
- [book] iOS 8 Swift Programming Cookbook
iOS 8 Swift Programming Cookbook 资源地址 http://pan.baidu.com/s/1c0hn1Gc 书籍介绍 源码截图 书籍截图
- C 转义字符说明
%a(%A) 浮点数.十六进制数字和p-(P-)记数法(C99)%c 字符%d 有符号十进制整数%f 浮点数(包括float和doulbe)%e(%E) 浮点数指数输出[e-(E-)记数法]%g(%G ...
- 【matlab】 幂法 求解最大特征值
一. 算法: 1.输入矩阵A,初始向量x误差限ep,最大迭代次数N 2.置 k = 1, m1 = 0; 3.求Xr-> norm(x) abs(Xr)=max[Xi] 1<=i< ...