第一个项目的cmd代码

mvn clean:target文件夹消失
mvn clean compile:target文件夹出现
mvn clean test:target文件夹出现两个新的文件夹
mvn clean package:出现Hello-0.0.1-SNAPSHOT.jar

C:\Users\asus>mvn -v
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-11T00:41:47+08:00)
Maven home: E:\studyfile\maven\Maven\apache-maven-3.3.9
Java version: 1.7.0_25, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk1.7.0_25\jre
Default locale: zh_CN, platform encoding: GBK
OS name: “windows 8”, version: “6.2”, arch: “amd64”, family: “windows”

C:\Users\asus>cd e
系统找不到指定的路径。

C:\Users\asus>cd e:
E:\

C:\Users\asus>e:

E:>cd studyfile

E:\studyfile>cd maven

E:\studyfile\maven>cd Hello

E:\studyfile\maven\Hello>mvn compile
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /E:/studyfile/maven/Hello/src/main/java/cn/rjxy/maven/Hello.java:[1,22] 需要’;’
[ERROR] /E:/studyfile/maven/Hello/src/main/java/cn/rjxy/maven/Hello.java:[4,41] 需要’;’
[INFO] 2 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 42.847 s
[INFO] Finished at: 2019-09-26T14:43:40+08:00
[INFO] Final Memory: 8M/122M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project Hello: Compilation failure: Compilation failure:
[ERROR] /E:/studyfile/maven/Hello/src/main/java/cn/rjxy/maven/Hello.java:[1,22] 需要’;’
[ERROR] /E:/studyfile/maven/Hello/src/main/java/cn/rjxy/maven/Hello.java:[4,41] 需要’;’
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

E:\studyfile\maven\Hello>mvn compile
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.928 s
[INFO] Finished at: 2019-09-26T14:44:16+08:00
[INFO] Final Memory: 11M/154M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>mvn clean
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.206 s
[INFO] Finished at: 2019-09-26T14:45:13+08:00
[INFO] Final Memory: 6M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.52.215] failed: Connection timed out: connect -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean compile
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 23.355 s
[INFO] Finished at: 2019-09-26T14:46:18+08:00
[INFO] Final Memory: 6M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.52.215] failed: Connection timed out: connect -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean clean
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.283 s
[INFO] Finished at: 2019-09-26T14:47:01+08:00
[INFO] Final Memory: 7M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): Received fatal alert: protocol_version -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 27.253 s
[INFO] Finished at: 2019-09-26T14:48:51+08:00
[INFO] Final Memory: 6M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.196.215] failed: Connection timed out: connect -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean install -u
Unable to parse command line options: Unrecognized option: -u

usage: mvn [options] [<goal(s)>] [<phase(s)>]

Options:
-am,–also-make If project list is specified, also
build projects required by the
list
-amd,–also-make-dependents If project list is specified, also
build projects that depend on
projects on the list
-B,–batch-mode Run in non-interactive (batch)
mode
-b,–builder The id of the build strategy to
use.
-C,–strict-checksums Fail the build if checksums don’t
match
-c,–lax-checksums Warn if checksums don’t match
-cpu,–check-plugin-updates Ineffective, only kept for
backward compatibility
-D,–define Define a system property
-e,–errors Produce execution error messages
-emp,–encrypt-master-password Encrypt master security password
-ep,–encrypt-password Encrypt server password
-f,–file Force the use of an alternate POM
file (or directory with pom.xml).
-fae,–fail-at-end Only fail the build afterwards;
allow all non-impacted builds to
continue
-ff,–fail-fast Stop at first failure in
reactorized builds
-fn,–fail-never NEVER fail the build, regardless
of project result
-gs,–global-settings Alternate path for the global
settings file
-gt,–global-toolchains Alternate path for the global
toolchains file
-h,–help Display help information
-l,–log-file Log file where all build output
will go.
-llr,–legacy-local-repository Use Maven 2 Legacy Local
Repository behaviour, ie no use of
_remote.repositories. Can also be
activated by using
-Dmaven.legacyLocalRepo=true
-N,–non-recursive Do not recurse into sub-projects
-npr,–no-plugin-registry Ineffective, only kept for
backward compatibility
-npu,–no-plugin-updates Ineffective, only kept for
backward compatibility
-nsu,–no-snapshot-updates Suppress SNAPSHOT updates
-o,–offline Work offline
-P,–activate-profiles Comma-delimited list of profiles
to activate
-pl,–projects Comma-delimited list of specified
reactor projects to build instead
of all projects. A project can be
specified by [groupId]:artifactId
or by its relative path.
-q,–quiet Quiet output - only show errors
-rf,–resume-from Resume reactor from specified
project
-s,–settings Alternate path for the user
settings file
-T,–threads Thread count, for instance 2.0C
where C is core multiplied
-t,–toolchains Alternate path for the user
toolchains file
-U,–update-snapshots Forces a check for missing
releases and updated snapshots on
remote repositories
-up,–update-plugins Ineffective, only kept for
backward compatibility
-V,–show-version Display version information
WITHOUT stopping build
-v,–version Display version information
-X,–debug Produce execution debug output

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 24.452 s
[INFO] Finished at: 2019-09-26T15:10:18+08:00
[INFO] Final Memory: 9M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.196.215] failed: Connection timed out: connect -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.358 s
[INFO] Finished at: 2019-09-26T15:14:05+08:00
[INFO] Final Memory: 7M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:jar:2.5 from/to central (https://repo.maven.apache.org/maven2): Received fatal alert: protocol_version -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.071 sec <<< FAILURE!
testHello(cn.rjxy.maven.HelloTest) Time elapsed: 0.024 sec <<< FAILURE!
junit.framework.ComparisonFailure: expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at cn.rjxy.maven.HelloTest.testHello(HelloTest.java:13)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:69)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:48)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner 2. e v a l u a t e ( P a r e n t R u n n e r . j a v a : 222 ) a t o r g . j u n i t . r u n n e r s . P a r e n t R u n n e r . r u n ( P a r e n t R u n n e r . j a v a : 292 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e ( J U n i t 4 P r o v i d e r . j a v a : 252 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e T e s t S e t ( J U n i t 4 P r o v i d e r . j a v a : 141 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . i n v o k e ( J U n i t 4 P r o v i d e r . j a v a : 112 ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e 0 ( N a t i v e M e t h o d ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e ( N a t i v e M e t h o d A c c e s s o r I m p l . j a v a : 57 ) a t s u n . r e f l e c t . D e l e g a t i n g M e t h o d A c c e s s o r I m p l . i n v o k e ( D e l e g a t i n g M e t h o d A c c e s s o r I m p l . j a v a : 43 ) a t j a v a . l a n g . r e f l e c t . M e t h o d . i n v o k e ( M e t h o d . j a v a : 606 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . u t i l . R e f l e c t i o n U t i l s . i n v o k e M e t h o d W i t h A r r a y ( R e f l e c t i o n U t i l s . j a v a : 189 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . b o o t e r . P r o v i d e r F a c t o r y 2.evaluate(ParentRunner.java:222) at org.junit.runners.ParentRunner.run(ParentRunner.java:292) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory 2.evaluate(ParentRunner.java:222)atorg.junit.runners.ParentRunner.run(ParentRunner.java:292)atorg.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)atorg.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)atorg.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:606)atorg.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)atorg.apache.maven.surefire.booter.ProviderFactoryProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)

Results :

Failed tests: testHello(cn.rjxy.maven.HelloTest): expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>

Tests run: 1, Failures: 1, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.905 s
[INFO] Finished at: 2019-09-26T15:14:50+08:00
[INFO] Final Memory: 13M/225M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project Hello: There are test failures.
[ERROR]
[ERROR] Please refer to E:\studyfile\maven\Hello\target\surefire-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

E:\studyfile\maven\Hello>mvn clean
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.362 s
[INFO] Finished at: 2019-09-26T15:16:45+08:00
[INFO] Final Memory: 6M/122M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>mvn clean compile
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.511 s
[INFO] Finished at: 2019-09-26T15:17:19+08:00
[INFO] Final Memory: 11M/122M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>mvn clean test
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.067 sec <<< FAILURE!
testHello(cn.rjxy.maven.HelloTest) Time elapsed: 0.012 sec <<< FAILURE!
junit.framework.ComparisonFailure: expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at cn.rjxy.maven.HelloTest.testHello(HelloTest.java:13)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:69)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:48)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner 2. e v a l u a t e ( P a r e n t R u n n e r . j a v a : 222 ) a t o r g . j u n i t . r u n n e r s . P a r e n t R u n n e r . r u n ( P a r e n t R u n n e r . j a v a : 292 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e ( J U n i t 4 P r o v i d e r . j a v a : 252 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e T e s t S e t ( J U n i t 4 P r o v i d e r . j a v a : 141 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . i n v o k e ( J U n i t 4 P r o v i d e r . j a v a : 112 ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e 0 ( N a t i v e M e t h o d ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e ( N a t i v e M e t h o d A c c e s s o r I m p l . j a v a : 57 ) a t s u n . r e f l e c t . D e l e g a t i n g M e t h o d A c c e s s o r I m p l . i n v o k e ( D e l e g a t i n g M e t h o d A c c e s s o r I m p l . j a v a : 43 ) a t j a v a . l a n g . r e f l e c t . M e t h o d . i n v o k e ( M e t h o d . j a v a : 606 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . u t i l . R e f l e c t i o n U t i l s . i n v o k e M e t h o d W i t h A r r a y ( R e f l e c t i o n U t i l s . j a v a : 189 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . b o o t e r . P r o v i d e r F a c t o r y 2.evaluate(ParentRunner.java:222) at org.junit.runners.ParentRunner.run(ParentRunner.java:292) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory 2.evaluate(ParentRunner.java:222)atorg.junit.runners.ParentRunner.run(ParentRunner.java:292)atorg.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)atorg.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)atorg.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:606)atorg.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)atorg.apache.maven.surefire.booter.ProviderFactoryProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)

Results :

Failed tests: testHello(cn.rjxy.maven.HelloTest): expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>

Tests run: 1, Failures: 1, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.939 s
[INFO] Finished at: 2019-09-26T15:19:18+08:00
[INFO] Final Memory: 13M/224M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project Hello: There are test failures.
[ERROR]
[ERROR] Please refer to E:\studyfile\maven\Hello\target\surefire-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.063 sec <<< FAILURE!
testHello(cn.rjxy.maven.HelloTest) Time elapsed: 0.013 sec <<< FAILURE!
junit.framework.ComparisonFailure: expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at cn.rjxy.maven.HelloTest.testHello(HelloTest.java:13)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:69)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:48)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner 2. e v a l u a t e ( P a r e n t R u n n e r . j a v a : 222 ) a t o r g . j u n i t . r u n n e r s . P a r e n t R u n n e r . r u n ( P a r e n t R u n n e r . j a v a : 292 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e ( J U n i t 4 P r o v i d e r . j a v a : 252 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e T e s t S e t ( J U n i t 4 P r o v i d e r . j a v a : 141 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . i n v o k e ( J U n i t 4 P r o v i d e r . j a v a : 112 ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e 0 ( N a t i v e M e t h o d ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e ( N a t i v e M e t h o d A c c e s s o r I m p l . j a v a : 57 ) a t s u n . r e f l e c t . D e l e g a t i n g M e t h o d A c c e s s o r I m p l . i n v o k e ( D e l e g a t i n g M e t h o d A c c e s s o r I m p l . j a v a : 43 ) a t j a v a . l a n g . r e f l e c t . M e t h o d . i n v o k e ( M e t h o d . j a v a : 606 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . u t i l . R e f l e c t i o n U t i l s . i n v o k e M e t h o d W i t h A r r a y ( R e f l e c t i o n U t i l s . j a v a : 189 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . b o o t e r . P r o v i d e r F a c t o r y 2.evaluate(ParentRunner.java:222) at org.junit.runners.ParentRunner.run(ParentRunner.java:292) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory 2.evaluate(ParentRunner.java:222)atorg.junit.runners.ParentRunner.run(ParentRunner.java:292)atorg.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)atorg.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)atorg.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:606)atorg.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)atorg.apache.maven.surefire.booter.ProviderFactoryProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)

Results :

Failed tests: testHello(cn.rjxy.maven.HelloTest): expected:<[H]ello litingwei!> but was:<[h]ello litingwei!>

Tests run: 1, Failures: 1, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.852 s
[INFO] Finished at: 2019-09-26T15:20:57+08:00
[INFO] Final Memory: 13M/225M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project Hello: There are test failures.
[ERROR]
[ERROR] Please refer to E:\studyfile\maven\Hello\target\surefire-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

E:\studyfile\maven\Hello>mvn clean test
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.065 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.766 s
[INFO] Finished at: 2019-09-26T15:24:21+08:00
[INFO] Final Memory: 15M/225M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>mvn clean package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.068 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] — maven-jar-plugin:2.4:jar (default-jar) @ Hello —
[INFO] Building jar: E:\studyfile\maven\Hello\target\Hello-0.0.1-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.161 s
[INFO] Finished at: 2019-09-26T15:25:10+08:00
[INFO] Final Memory: 15M/224M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>mvn clean install
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Hello 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ Hello —
[INFO] Deleting E:\studyfile\maven\Hello\target
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ Hello —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ Hello —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\Hello\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ Hello —
[INFO] Surefire report directory: E:\studyfile\maven\Hello\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.057 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] — maven-jar-plugin:2.4:jar (default-jar) @ Hello —
[INFO] Building jar: E:\studyfile\maven\Hello\target\Hello-0.0.1-SNAPSHOT.jar
[INFO]
[INFO] — maven-install-plugin:2.4:install (default-install) @ Hello —
[INFO] Installing E:\studyfile\maven\Hello\target\Hello-0.0.1-SNAPSHOT.jar to C:\Users\asus.m2\repository\cn\rjxy\maven\Hello\0.0.1-SNAPSHOT\Hello-0.0.1-SNAPSHOT.jar
[INFO] Installing E:\studyfile\maven\Hello\pom.xml to C:\Users\asus.m2\repository\cn\rjxy\maven\Hello\0.0.1-SNAPSHOT\Hello-0.0.1-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.194 s
[INFO] Finished at: 2019-09-26T15:40:07+08:00
[INFO] Final Memory: 17M/224M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\Hello>cd …

E:\studyfile\maven>cd …/

E:\studyfile>cd maven

E:\studyfile\maven>cd HelloFriend

E:\studyfile\maven\HelloFriend>mvn package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building HelloFriend 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ HelloFriend —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ HelloFriend —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\HelloFriend\target\classes
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ HelloFriend —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ HelloFriend —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\HelloFriend\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ HelloFriend —
[INFO] Surefire report directory: E:\studyfile\maven\HelloFriend\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloFriendTest
hello litingwei! I am John
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.063 sec <<< FAILURE!
tesHelloFriend(cn.rjxy.maven.HelloFriendTest) Time elapsed: 0.013 sec <<< FAILURE!
junit.framework.ComparisonFailure: expected:<[H]ello litingwei! I am…> but was:<[h]ello litingwei! I am…>
at junit.framework.Assert.assertEquals(Assert.java:85)
at junit.framework.Assert.assertEquals(Assert.java:91)
at cn.rjxy.maven.HelloFriendTest.tesHelloFriend(HelloFriendTest.java:16)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:69)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:48)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner 2. e v a l u a t e ( P a r e n t R u n n e r . j a v a : 222 ) a t o r g . j u n i t . r u n n e r s . P a r e n t R u n n e r . r u n ( P a r e n t R u n n e r . j a v a : 292 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e ( J U n i t 4 P r o v i d e r . j a v a : 252 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . e x e c u t e T e s t S e t ( J U n i t 4 P r o v i d e r . j a v a : 141 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . j u n i t 4. J U n i t 4 P r o v i d e r . i n v o k e ( J U n i t 4 P r o v i d e r . j a v a : 112 ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e 0 ( N a t i v e M e t h o d ) a t s u n . r e f l e c t . N a t i v e M e t h o d A c c e s s o r I m p l . i n v o k e ( N a t i v e M e t h o d A c c e s s o r I m p l . j a v a : 57 ) a t s u n . r e f l e c t . D e l e g a t i n g M e t h o d A c c e s s o r I m p l . i n v o k e ( D e l e g a t i n g M e t h o d A c c e s s o r I m p l . j a v a : 43 ) a t j a v a . l a n g . r e f l e c t . M e t h o d . i n v o k e ( M e t h o d . j a v a : 606 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . u t i l . R e f l e c t i o n U t i l s . i n v o k e M e t h o d W i t h A r r a y ( R e f l e c t i o n U t i l s . j a v a : 189 ) a t o r g . a p a c h e . m a v e n . s u r e f i r e . b o o t e r . P r o v i d e r F a c t o r y 2.evaluate(ParentRunner.java:222) at org.junit.runners.ParentRunner.run(ParentRunner.java:292) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory 2.evaluate(ParentRunner.java:222)atorg.junit.runners.ParentRunner.run(ParentRunner.java:292)atorg.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)atorg.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)atorg.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:606)atorg.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)atorg.apache.maven.surefire.booter.ProviderFactoryProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)

Results :

Failed tests: tesHelloFriend(cn.rjxy.maven.HelloFriendTest): expected:<[H]ello litingwei! I am…> but was:<[h]ello litingwei! I am…>

Tests run: 1, Failures: 1, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.962 s
[INFO] Finished at: 2019-09-26T15:40:53+08:00
[INFO] Final Memory: 14M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project HelloFriend: There are test failures.
[ERROR]
[ERROR] Please refer to E:\studyfile\maven\HelloFriend\target\surefire-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

E:\studyfile\maven\HelloFriend>mvn package
[INFO] Scanning for projects…
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building HelloFriend 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ HelloFriend —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ HelloFriend —
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ HelloFriend —
[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO]
[INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ HelloFriend —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding GBK, i.e. build is platform dependent!
[INFO] Compiling 1 source file to E:\studyfile\maven\HelloFriend\target\test-classes
[INFO]
[INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ HelloFriend —
[INFO] Surefire report directory: E:\studyfile\maven\HelloFriend\target\surefire-reports


T E S T S

Running cn.rjxy.maven.HelloFriendTest
hello litingwei! I am John
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.063 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] — maven-jar-plugin:2.4:jar (default-jar) @ HelloFriend —
[INFO] Building jar: E:\studyfile\maven\HelloFriend\target\HelloFriend-0.0.1-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.090 s
[INFO] Finished at: 2019-09-26T15:42:22+08:00
[INFO] Final Memory: 14M/224M
[INFO] ------------------------------------------------------------------------

E:\studyfile\maven\HelloFriend>java -v
Unrecognized option: -v
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

E:\studyfile\maven\HelloFriend>java -version
java version “1.7.0_25”
Java™ SE Runtime Environment (build 1.7.0_25-b17)
Java HotSpot™ 64-Bit Server VM (build 23.25-b01, mixed mode)

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
在VS Code中创建一个项目的步骤如下: 1. 首先,创建一个空文件夹来存放项目,可以命名为projects。 2. 在空文件夹下创建一个子文件夹作为工作台,比如helloworld,这将成为你的workspace。 3. 打开命令提示符(cmd)并导航到projects文件夹,使用以下命令:mkdir projects,cd projects。 4. 在工作台文件夹(helloworld)中打开VS Code,可以使用以下命令:code . 。 5. 这样就会直接打开VS Code,并将工作台文件夹作为工作区打开。 6. 在工作区的文件夹中,会创建三个.vscode文件,这些文件包含了工作区的配置信息和其他设置。\[1\] 如果你想保存这个工作区,可以调出命令面板,搜索"将工作区另存为" (save workspace as),然后为工作区创建一个.code-workspace文件。这个文件将保存工作区的配置信息和其他设置。\[2\] 以上是使用VS Code创建一个项目的基本步骤。你可以根据需要在工作区中进行代码编写、调试和其他操作。\[3\] #### 引用[.reference_title] - *1* *3* [VScode创建第一个C++项目](https://blog.csdn.net/qq_40260394/article/details/109698024)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] - *2* [VSCode 多文件夹工作区](https://blog.csdn.net/weixin_33171271/article/details/113011427)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值