Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 1,485 for mock3 (0.04 sec)

  1. testing/internal-testing/src/main/groovy/org/gradle/test/fixtures/concurrent/ConcurrentSpec.groovy

     * instant has been reached.
     *
     * <p>The main test thread cannot define instants, except within an {@link #async} block.
     *
     * <p>NOTE: Be careful when using this class with Spock mock objects, as these mocks perform some synchronisation of their own. This means that you may not be testing
     * what you think you are testing.
     */
    @Timeout(60)
    class ConcurrentSpec extends Specification {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  2. platforms/core-execution/execution/src/test/groovy/org/gradle/internal/execution/steps/AssignImmutableWorkspaceStepConcurrencyTest.groovy

            temporaryWorkspace2.assertDoesNotExist()
            immutableWorkspace.file("work.txt").text == "work1"
            0 * _
        }
    
        // We need custom mock classes because Spock does not support multi-threaded mocks
    
        private static class MockStep implements Step<WorkspaceContext, CachingResult> {
            BiFunction<UnitOfWork, WorkspaceContext, CachingResult> expectCall
    
            @Override
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Nov 22 09:46:25 UTC 2023
    - 6.5K bytes
    - Viewed (0)
  3. pkg/kubelet/container/testing/os.go

    See the License for the specific language governing permissions and
    limitations under the License.
    */
    
    package testing
    
    import (
    	"errors"
    	"os"
    	"sync"
    	"time"
    )
    
    // FakeOS mocks out certain OS calls to avoid perturbing the filesystem
    // If a member of the form `*Fn` is set, that function will be called in place
    // of the real call.
    type FakeOS struct {
    	StatFn     func(string) (os.FileInfo, error)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Feb 07 13:37:31 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  4. mockwebserver/README.md

    awkward-to-reproduce situations like 500 errors or slow-loading responses.
    
    
    ### Example
    
    Use MockWebServer the same way that you use mocking frameworks like
    [Mockito](https://github.com/mockito/mockito):
    
    1. Script the mocks.
    2. Run application code.
    3. Verify that the expected requests were made.
    
    Here's a complete example:
    
    ```java
    public void test() throws Exception {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sun Dec 17 15:34:10 UTC 2023
    - 5K bytes
    - Viewed (0)
  5. pkg/volume/flexvolume/probe_test.go

    	f, _ := fs.Create(filepath.Join(driverPath, driverName))
    	f.Close()
    }
    
    // Initializes mocks, installs a single driver in the mock fs, then initializes prober.
    func initTestEnvironment(t *testing.T) (
    	driverPath string,
    	fs utilfs.Filesystem,
    	watcher *fakeWatcher,
    	prober volume.DynamicPluginProber) {
    	fs = utilfs.NewTempFs()
    	watcher = newFakeWatcher()
    	prober = &flexVolumeProber{
    		pluginDir: pluginDir,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Nov 28 11:14:00 UTC 2023
    - 10.5K bytes
    - Viewed (0)
  6. platforms/core-configuration/configuration-cache/src/test/kotlin/org/gradle/internal/cc/impl/serialization/codecs/AbstractUserTypeCodecTest.kt

            objectFactory = mock(),
            instantiator = mock(),
            fileSystemOperations = mock(),
            taskNodeFactory = mock(),
            ordinalGroupFactory = mock(),
            inputFingerprinter = mock(),
            buildOperationRunner = mock(),
            classLoaderHierarchyHasher = mock(),
            isolatableFactory = mock(),
            managedFactoryRegistry = mock(),
            parameterScheme = mock(),
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Sat Jun 08 11:29:30 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  7. .teamcity/src/test/kotlin/ApplyDefaultConfigurationTest.kt

    import common.pluginPortalUrlOverride
    import configurations.BaseGradleBuildType
    import configurations.applyDefaults
    import configurations.applyTestDefaults
    import io.mockk.every
    import io.mockk.impl.annotations.MockK
    import io.mockk.junit5.MockKExtension
    import io.mockk.mockk
    import io.mockk.slot
    import jetbrains.buildServer.configs.kotlin.BuildStep
    import jetbrains.buildServer.configs.kotlin.BuildSteps
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Jun 04 06:42:07 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  8. platforms/software/dependency-management/src/test/groovy/org/gradle/api/internal/artifacts/dsl/DefaultRepositoryHandlerTest.groovy

            given:
            def repo1 = Mock(TestMavenArtifactRepository) { getName() >> "Maven repo 1" }
            def repo2 = Mock(TestMavenArtifactRepository) { getName() >> "Maven repo 2" }
            def repo3 = Mock(TestMavenArtifactRepository) { getName() >> "Maven repo 3" }
            def repo1Content = Mock(RepositoryContentDescriptor)
            def repo2Content = Mock(RepositoryContentDescriptor)
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jan 25 18:02:33 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  9. platforms/ide/tooling-api/src/test/groovy/org/gradle/tooling/internal/consumer/parameters/BuildProgressListenerAdapterForTestOperationsTest.groovy

            given:
            def listener = Mock(ProgressListener)
            def adapter = createAdapter(listener)
    
            when:
            def testDescriptor = Mock(InternalTestDescriptor)
            _ * testDescriptor.getId() >> 1
            _ * testDescriptor.getName() >> 'some test suite'
            _ * testDescriptor.getParentId() >> null
    
            def startEvent = Mock(InternalTestStartedProgressEvent)
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Sep 26 14:49:20 UTC 2023
    - 20.5K bytes
    - Viewed (0)
  10. subprojects/core/src/test/groovy/org/gradle/api/internal/file/archive/ZipCopyActionTest.groovy

            mock
        }
    
        private FileCopyDetailsInternal dir(final String path) {
            def mock = Mock(FileCopyDetailsInternal)
            mock.getRelativePath() >> RelativePath.parse(false, path)
            mock.getLastModified() >> 1000L
            mock.isDirectory() >> true
            mock.getPermissions() >> new DefaultFilePermissions(2)
            mock
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Jun 22 14:26:33 UTC 2023
    - 6.6K bytes
    - Viewed (0)
Back to top