Skip to content

Instantly share code, notes, and snippets.

@djsauble
Created February 26, 2018 21:11
Show Gist options
  • Save djsauble/c4c6fd779da12adc4d5b0c8e69407a26 to your computer and use it in GitHub Desktop.
Save djsauble/c4c6fd779da12adc4d5b0c8e69407a26 to your computer and use it in GitHub Desktop.
Tests fail when setting trial length to 91
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running com.sonatype.firewall.core.DateUtilTest
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.084 sec <<< FAILURE!
testGetExpirationDate(com.sonatype.firewall.core.DateUtilTest) Time elapsed: 0.029 sec <<< FAILURE!
java.lang.AssertionError:
Expected: is "2018/02/18"
but: was "2018/05/28"
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:8)
at com.sonatype.firewall.core.DateUtilTest.testGetExpirationDate(DateUtilTest.java:15)
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.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.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
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.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: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.invokeMethodWithArray(ReflectionUtils.java:189)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.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)
Running com.sonatype.firewall.resources.RootResourceTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.157 sec
Running com.sonatype.firewall.resources.FirewallLicenseResourceTest
13:10:06.382 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to generate license for name=John Doe email=jdoe@email.com company=Sonatype
13:10:06.386 [main] ERROR com.sonatype.firewall.resources.FirewallLicenseResource - Failed to create license 401 Not authorized
13:10:06.389 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve licenses for email=email
13:10:06.390 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve license file for id=licenseId
13:10:06.390 [main] ERROR com.sonatype.firewall.resources.FirewallLicenseResource - Failed to get license file for id=licenseId 401 Not authorized
13:10:06.391 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve license file for id=licenseId
13:10:06.391 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - No license file found for id=licenseId
13:10:06.392 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to generate license for name=John Doe email=jdoe@email.com company=Sonatype
13:10:06.392 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Successfully created license fingerprint=FINGERPRINT id=ID
13:10:06.393 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve licenses for email=email
13:10:06.393 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - No licenses found for email=email
13:10:06.394 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve license file for id=licenseId
13:10:06.394 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Successfully retrieved license file for id=licenseId
13:10:06.401 [main] DEBUG com.sonatype.firewall.resources.FirewallLicenseResource - Received request to retrieve licenses for email=email
13:10:06.401 [main] ERROR com.sonatype.firewall.resources.FirewallLicenseResource - Failed to get licenses for email=email 401 Not authorized
Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.475 sec
Running com.sonatype.firewall.client.licensemanager.LicenseManagerClientTest
Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.124 sec
Results :
Failed tests: testGetExpirationDate(com.sonatype.firewall.core.DateUtilTest): (..)
Tests run: 14, Failures: 1, Errors: 0, Skipped: 0
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.223 s
[INFO] Finished at: 2018-02-26T13:10:06-08:00
[INFO] Final Memory: 27M/309M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project firewall-license-manager: There are test failures.
[ERROR]
[ERROR] Please refer to /Users/danielsauble/Projects/work/firewall-license-manager/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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment