Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 14 for assertThatCause (0.31 sec)

  1. platforms/jvm/plugins-jvm-test-suite/src/integTest/groovy/org/gradle/testing/testsuites/TestSuitesMultiTargetIntegrationTest.groovy

            """
    
            when:
            withInstallations(Jvm.current(), otherJvm).fails("testAggregateTestReport")
    
            then:
            failure.assertThatCause(containsNormalizedString("There are several available matching variants of project :"))
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue May 28 15:55:38 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  2. subprojects/core/src/integTest/groovy/org/gradle/api/BuildScriptErrorIntegrationTest.groovy

                    toolchains { // should be toolchain
                    }
                }
            """
    
            expect:
            fails()
            failure.assertThatCause(containsNormalizedString("Could not find method toolchains() for arguments"))
            failure.assertThatCause(containsNormalizedString(" on extension 'java' of type org.gradle.api.plugins.internal.DefaultJavaPluginExtension."))
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri May 17 17:01:37 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  3. testing/internal-integ-testing/src/main/groovy/org/gradle/integtests/fixtures/executer/ErrorsOnStdoutScrapingExecutionFailure.java

        public ExecutionFailure assertHasCause(String description) {
            delegate.assertHasCause(description);
            return this;
        }
    
        @Override
        public ExecutionFailure assertThatCause(Matcher<? super String> matcher) {
            delegate.assertThatCause(matcher);
            return this;
        }
    
        @Override
        public ExecutionFailure assertHasDescription(String context) {
            delegate.assertHasDescription(context);
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 11 09:21:25 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  4. platforms/software/dependency-management/src/integTest/groovy/org/gradle/integtests/resolve/rules/ComponentAttributesRulesIntegrationTest.groovy

                failure.assertThatCause(containsNormalizedString("The only attribute distinguishing these variants is 'org.gradle.usage'. Add this attribute to the consumer's configuration to resolve the ambiguity:"))
                failure.assertThatCause(containsNormalizedString("- Value: 'unknownApiVariant' selects variant: 'api'"))
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue May 28 15:10:53 UTC 2024
    - 16.7K bytes
    - Viewed (0)
  5. subprojects/core/src/integTest/groovy/org/gradle/plugin/ScriptPluginClassLoadingIntegrationTest.groovy

                someMethod()
            """
    
            when:
            fails "help"
    
            then:
            failure.assertHasFileName("Script '${file("script2.gradle").absolutePath}'")
            failure.assertThatCause(containsText("Could not find method someMethod()"))
        }
    
        def "methods defined in settings script are not inherited by scripts"() {
            given:
            settingsFile << """
                def someMethod() {}
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri May 17 13:27:34 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  6. platforms/core-configuration/declarative-dsl-provider/src/integTest/groovy/org/gradle/internal/declarativedsl/settings/SoftwareTypeDeclarationIntegrationTest.groovy

                    nonPublic = "foo"
                }
            """
            fails(":printTestSoftwareTypeExtensionImplConfiguration")
    
            then:
            failure.assertThatCause(Matchers.containsString("Failed to interpret the declarative DSL file"))
            failure.assertThatCause(Matchers.containsString("unresolved reference 'nonPublic'"))
        }
    
        def 'can declare and configure a custom software type from a parent class'() {
            given:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Sun May 19 16:59:01 UTC 2024
    - 11K bytes
    - Viewed (0)
  7. platforms/extensibility/plugin-development/src/integTest/groovy/org/gradle/plugin/devel/tasks/ValitdatePluginsTrait.groovy

            messages.forEach { problem ->
                String indentedMessage = problem.message.replaceAll('\n', '\n    ').trim()
                failure.assertThatCause(containsString("$problem.severity: $indentedMessage"))
            }
    
            // TODO (donat) do probably don't want to have this, as the explicit problem assertions are preferred
            def problems = collectedProblems
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed May 15 14:30:05 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  8. testing/internal-integ-testing/src/main/groovy/org/gradle/integtests/fixtures/executer/OutputScrapingExecutionFailure.java

            }
            return this;
        }
    
        @Override
        public ExecutionFailure assertHasCause(String description) {
            assertThatCause(startsWith(description));
            return this;
        }
    
        @Override
        public ExecutionFailure assertThatCause(Matcher<? super String> matcher) {
            Set<String> seen = new LinkedHashSet<>();
            for (Problem problem : problems) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 11 09:21:25 UTC 2024
    - 12.5K bytes
    - Viewed (0)
  9. testing/internal-integ-testing/src/main/groovy/org/gradle/integtests/fixtures/executer/ExecutionFailure.java

         * Asserts that there is a failure present with the given cause (ie the bit after the description).
         *
         * <p>Error messages are normalized to use new-line char as line separator.
         */
        ExecutionFailure assertThatCause(Matcher<? super String> matcher);
    
        /**
         * Asserts that there is a failure present with the given description (ie the bit after '* What went wrong').
         *
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 11 09:21:25 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  10. subprojects/core/src/integTest/groovy/org/gradle/api/internal/model/ObjectFactoryNamedTypeIntegrationTest.groovy

            then:
            failure.assertHasCause("Cannot set readonly property: name for class: Thing\$Impl")
    
            when:
            fails("changeDynProp")
    
            then:
            failure.assertThatCause(allOf(
                startsWith("No signature of method: Thing\$Impl"),
                containsString(".setProperty() is applicable for argument types: (String, String) values: [name, 123]")
            ))
    
            when:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Apr 17 05:39:53 UTC 2024
    - 6.2K bytes
    - Viewed (0)
Back to top