Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LPS-107459 FIX NullPointerException on JournalFolderTrashHandlerTest.testDeleteTrashVersions() due to null JournalFolderLocalService from registry when integration test starts before dependency injection finishes #83679

Conversation

arboliveira
Copy link

❌ ci:test:search - 47 out of 50 jobs passed in 1 hour 30 minutes 5 seconds 353 ms
arboliveira#798 (comment)


Failures are unrelated, QA aware. Ran baseline post warning.


https://issues.liferay.com/browse/LPS-107459

- Introduce JournalFolderFixture
- Reimplement addFolder methods from JournalTestUtil
- Require a non null JournalFolderLocalService (thus injected)
- Deprecate old methods using unreliable JournalFolderLocalServiceUtil
- Seriously, do not rely on Util stuff wherever anymore, it's 2020

https://issues.liferay.com/browse/LPS-107459
@liferay-continuous-integration
Copy link
Collaborator

CI is automatically triggering "ci:test:sf" and "ci:test:relevant" for this pull to run Source Formatter and relevant tests.

Comment "ci:test" to run the full PR Tester for this pull.

@liferay-continuous-integration
Copy link
Collaborator

✔️ ci:test:sf - 1 out of 1 jobs passed in 3 minutes 15 seconds 615 ms

Click here for more details.

Base Branch:

Branch Name: master
Branch GIT ID: c4beacb3c7c3ded127db62c059ecc90ec2e83b3c

Sender Branch:

Branch Name: LPS-107459-JournalTrashHandlerTest_null_JournalFolderLocalService
Branch GIT ID: e4fdb4274ea92b1b43c2af968dfda342f201e9fe

1 out of 1jobs PASSED
1 Successful Jobs:
For more details click here.

@brianchandotcom
Copy link
Owner

Merged. Thank you.
View total diff: c4beacb...1a949f6

@liferay-continuous-integration
Copy link
Collaborator

❌ ci:test:stable - 8 out of 9 jobs passed

❌ ci:test:relevant - 30 out of 33 jobs passed in 1 hour 32 minutes 855 ms

Click here for more details.

Base Branch:

Branch Name: master
Branch GIT ID: 63eea9b2c1b3141cc1e0bbb38e453f618eca4c7d

Copied in Private Modules Branch:

Branch Name: master-private
Branch GIT ID: 675fd6f1716b42f77cc332cad8893e473d800091

ci:test:stable - 8 out of 9 jobs PASSED
8 Successful Jobs:
ci:test:relevant - 30 out of 33 jobs PASSED
30 Successful Jobs:
For more details click here.

This pull contains no unique failures.


Failures in common with acceptance upstream results at 9186340:
  1. test-portal-acceptance-pullrequest-batch(master)/modules-integration-mysql57-jdk8
    Job Results:

    1728 Tests Passed.
    93 Tests Failed.

    1. AXIS_VARIABLE=0,label_exp=!master #319740
      1. BlogPostingResourceTest.testDeleteBlogPosting
        java.lang.AssertionError: Thread Thread[http-nio-8080-exec-6,5,main] caught concurrent failure: java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        	at com.liferay.portal.test.rule.LogAssertionAppender.append(LogAssertionAppender.java:60)
        	at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:251)
        	at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:66)
        	at org.apache.log4j.Category.callAppenders(Category.java:206)
        	at org.apache.log4j.Category.forcedLog(Category.java:391)
        	at org.apache.log4j.Category.log(Category.java:856)
        	at com.liferay.portal.log.Log4jLogImpl.error(Log4jLogImpl.java:54)
        	at com.liferay.portal.kernel.log.LogWrapper.error(LogWrapper.java:69)
        	at com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper.getProblem(ExceptionMapper.java:31)
        	at com.liferay.portal.vulcan.internal.jaxrs.exc...
      2. BlogPostingResourceTest.testDeleteBlogPostingMyRating
        java.lang.AssertionError: Thread Thread[http-nio-8080-exec-7,5,main] caught concurrent failure: java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        	at com.liferay.portal.test.rule.LogAssertionAppender.append(LogAssertionAppender.java:60)
        	at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:251)
        	at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:66)
        	at org.apache.log4j.Category.callAppenders(Category.java:206)
        	at org.apache.log4j.Category.forcedLog(Category.java:391)
        	at org.apache.log4j.Category.log(Category.java:856)
        	at com.liferay.portal.log.Log4jLogImpl.error(Log4jLogImpl.java:54)
        	at com.liferay.portal.kernel.log.LogWrapper.error(LogWrapper.java:69)
        	at com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper.getProblem(ExceptionMapper.java:31)
        	at com.liferay.portal.vulcan.internal.jaxrs.exc...
      3. BlogPostingResourceTest.testGetBlogPosting
        java.lang.AssertionError: Thread Thread[http-nio-8080-exec-8,5,main] caught concurrent failure: java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        java.lang.AssertionError: {level=ERROR, loggerName=com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper, message=java.lang.RuntimeException: java.lang.ClassCastException: com.liferay.portal.vulcan.internal.accept.language.AcceptLanguageImpl cannot be cast to com.liferay.oauth2.provider.scope.ScopeChecker
        	at com.liferay.portal.test.rule.LogAssertionAppender.append(LogAssertionAppender.java:60)
        	at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:251)
        	at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:66)
        	at org.apache.log4j.Category.callAppenders(Category.java:206)
        	at org.apache.log4j.Category.forcedLog(Category.java:391)
        	at org.apache.log4j.Category.log(Category.java:856)
        	at com.liferay.portal.log.Log4jLogImpl.error(Log4jLogImpl.java:54)
        	at com.liferay.portal.kernel.log.LogWrapper.error(LogWrapper.java:69)
        	at com.liferay.portal.vulcan.internal.jaxrs.exception.mapper.ExceptionMapper.getProblem(ExceptionMapper.java:31)
        	at com.liferay.portal.vulcan.internal.jaxrs.exc...
      4. ...
    2. AXIS_VARIABLE=1,label_exp=!master #319740
      1. JournalArticleSearchTest.testOrderByDDMNumberFieldRepeatable
        org.junit.ComparisonFailure: expected:<{3.14,20|12.34,16[.0]}> but was:<{3.14,20|12.34,16[]}>
        	at org.junit.Assert.assertEquals(Assert.java:115)
        	at org.junit.Assert.assertEquals(Assert.java:144)
        	at com.liferay.dynamic.data.mapping.test.util.search.TestOrderHelper.assertSearch(TestOrderHelper.java:232)
        	at com.liferay.dynamic.data.mapping.test.util.search.TestOrderHelper.testOrderByDDMField(TestOrderHelper.java:358)
        	at com.liferay.dynamic.data.mapping.test.util.search.TestOrderHelper.testOrderByDDMFieldRepeatable(TestOrderHelper.java:397)
        	at com.liferay.dynamic.data.mapping.test.util.search.TestOrderHelper.testOrderByDDMNumberFieldRepeatable(TestOrderHelper.java:119)
        	at com.liferay.journal.search.test.JournalArticleSearchTest.testOrderByDDMNumberFieldRepeatable(JournalArticleSearchTest.java:246)
        	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 com.liferay.arquillian.extension.junit.bridge.server.TestExecutorRunnable$2.evaluate(TestExecutorRunnable.java:234)
        	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
        	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
        	at com.liferay.portal.kernel.test.rule.AbstractTestRule$2.evaluate(AbstractTestRule.java:99)
        	at com.liferay.porta...
  2. test-portal-acceptance-pullrequest-batch(master)/modules-unit-project-templates-jdk8
    Job Results:

    210 Tests Passed.
    1 Test Failed.

    1. AXIS_VARIABLE=0,label_exp=!master #363609
      1. ProjectTemplateFilesTest.testProjectTemplateFiles
        org.junit.ComparisonFailure: Forbidden leading or trailing whitespaces in ../project-templates-form-field/src/main/resources/archetype-resources/.babelrc.js expected:<...liferay-project"]
        };[]> but was:<...liferay-project"]
        };[
        ]>
        	at org.junit.Assert.assertEquals(Assert.java:115)
        	at com.liferay.project.templates.ProjectTemplateFilesTest._testTextFile(ProjectTemplateFilesTest.java:926)
        	at com.liferay.project.templates.ProjectTemplateFilesTest._testTextFile(ProjectTemplateFilesTest.java:951)
        	at com.liferay.project.templates.ProjectTemplateFilesTest.access$400(ProjectTemplateFilesTest.java:70)
        	at com.liferay.project.templates.ProjectTemplateFilesTest$1.visitFile(ProjectTemplateFilesTest.java:895)
        	at com.liferay.project.templates.ProjectTemplateFilesTest$1.visitFile(ProjectTemplateFilesTest.java:840)
        	at java.nio.file.Files.walkFileTree(Files.java:2670)
        	at java.nio.file.Files.walkFileTree(Files.java:2742)
        	at com.liferay.project.templates.ProjectTemplateFilesTest._testProjectTemplateFiles(ProjectTemplateFilesTest.java:838)
        	at com.liferay.project.templates.ProjectTemplateFilesTest.testProjectTemplateFiles(ProjectTemplateFilesTest.java:84)
        	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.ru...

@arboliveira arboliveira deleted the LPS-107459-JournalTrashHandlerTest_null_JournalFolderLocalService branch January 24, 2020 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants