Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 30 for equals (0.17 sec)

  1. platforms/core-runtime/functional/src/test/groovy/org/gradle/internal/TryTest.groovy

            then:
            a !== b
            a.equals(a)
            a.equals(b)
            b.equals(a)
        }
    
        def "can compare null-holding try with non-null"() {
            when:
            def a = Try.successful(null as String)
            def b = Try.successful("value")
    
            then:
            !a.equals(b)
            !b.equals(a)
        }
    
        def "null try has a hashcode"() {
            when:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 18 08:10:49 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  2. platforms/extensibility/plugin-development/src/integTest/resources/org/gradle/compile/daemon/ParallelCompilerDaemonIntegrationTest/shared/GroovyClass.groovy

            return result;
        }
    
        @Override
        public boolean equals(Object obj) {
            if (obj == this) {
                return true;
            }
            if (obj == null || obj.getClass() != getClass()) {
                return false;
            }
            GroovyClass other = (GroovyClass) obj;
            return files.equals(other.files);
        }
    
        @Override
        public int hashCode() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon May 06 13:27:57 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  3. testing/internal-performance-testing/src/test/groovy/org/gradle/performance/measure/AmountTest.groovy

            1     | Fruit.apples     | Fruit.oranges    | 0.333333
        }
    
        def "amounts are equal when normalised values are the same"() {
            expect:
            def a = Amount.valueOf(valueA, unitsA)
            def b = Amount.valueOf(valueB, unitsB)
            a.equals(b)
            b.equals(a)
            a.hashCode() == b.hashCode()
            a.compareTo(b) == 0
            b.compareTo(a) == 0
    
            where:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 9.4K bytes
    - Viewed (0)
  4. platforms/jvm/plugins-application/src/integTest/groovy/org/gradle/api/plugins/ProjectInternalViewDependencyIntegrationTest.groovy

                        // `implementation` dependencies are accessible
                        assert new com.fasterxml.jackson.databind.ObjectMapper().readTree("{\\\"hello\\\": \\\"test\\\"}").get("hello").asText().equals("test");
    
                        // `compileOnly` dependencies are accessible at compile-time
                        try {
                            assert org.apache.commons.lang3.StringUtils.length("Hello, Gradle!") == 14;
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Feb 28 23:38:57 UTC 2024
    - 5K bytes
    - Viewed (0)
  5. subprojects/core/src/test/groovy/org/gradle/api/internal/project/DefaultIsolatedProjectSpec.groovy

    class DefaultIsolatedProjectSpec extends Specification {
    
        def "delegates equals and hashCode to project"() {
            given:
            def project = Mock(ProjectInternal)
            def subject = new DefaultIsolatedProject(project, project)
    
            when:
            def hashCode = subject.hashCode()
            def equality = subject.equals(new DefaultIsolatedProject(project, project))
    
            then:
            hashCode == 42
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Mar 22 13:01:58 UTC 2024
    - 1.2K bytes
    - Viewed (0)
  6. platforms/core-runtime/serialization/src/test/groovy/org/gradle/internal/serialize/DefaultSerializerTest.groovy

            DefaultSerializer rhsSerializer = new DefaultSerializer(getClass().classLoader)
            DefaultSerializer lhsSerializer = new DefaultSerializer(getClass().classLoader)
    
            when:
            def areEquals = rhsSerializer.equals(lhsSerializer);
    
            then:
            areEquals
        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Apr 15 16:06:56 UTC 2024
    - 1.5K bytes
    - Viewed (0)
  7. platforms/jvm/toolchains-jvm-shared/src/test/groovy/org/gradle/jvm/toolchain/internal/DefaultToolchainSpecTest.groovy

    class DefaultToolchainSpecTest extends Specification {
        JavaToolchainSpec createSpec() {
            TestUtil.objectFactory().newInstance(DefaultToolchainSpec)
        }
    
        def "spec key implements equals"() {
            given:
            def spec11 = createSpec()
            def spec12 = createSpec()
            def spec11Vendor1 = createSpec()
            def spec11Vendor2 = createSpec()
            def spec11Impl1 = createSpec()
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Apr 10 18:03:55 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  8. subprojects/core/src/test/groovy/org/gradle/api/internal/file/copy/NormalizingCopyActionDecoratorTest.groovy

                }
    
                boolean matches(Object o) {
                    FileCopyDetails details = (FileCopyDetails) o
                    return details.getRelativePath().getPathString().equals(path)
                }
            }
        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Jan 22 14:38:33 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  9. testing/internal-integ-testing/src/main/groovy/org/gradle/integtests/fixtures/BuildOperationNotificationsFixture.groovy

                        verify(notification.getNotificationOperationResult(), 'Result')
                    }
    
                    private void verify(Object obj, String suffix = null) {
                        if (obj.getClass().getName().equals("org.gradle.internal.operations.OperationProgressDetails")) {
                            // This progress notification is emitted by Gradle itself.
                            return;
                        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 5.5K bytes
    - Viewed (0)
  10. testing/soak/src/testFixtures/groovy/org/gradle/launcher/daemon/fixtures/FullyQualifiedGarbageCollector.groovy

                } else {
                    return vendorComparison
                }
            } else {
                return gcComparison
            }
        }
    
        boolean equals(o) {
            if (this.is(o)) {
                return true
            }
            if (getClass() != o.class) {
                return false
            }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 2.3K bytes
    - Viewed (0)
Back to top