Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for injectEvents (0.24 sec)

  1. platforms/core-runtime/launcher/src/integTest/groovy/org/gradle/launcher/daemon/server/health/gc/GarbageCollectionMonitoringIntegrationTest.groovy

            when:
            run "injectEvents"
    
            then:
            daemons.daemon.becomesIdle()
            !output.contains("The Daemon will expire")
        }
    
        def "does not expire daemon when leak does not consume metaspace threshold"() {
            given:
            configureGarbageCollectionNonHeapEventsFor(256, 512, 5, 0)
    
            when:
            run "injectEvents"
    
            then:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 09:29:13 UTC 2023
    - 14.2K bytes
    - Viewed (0)
  2. pkg/filewatcher/fakefilewatcher_test.go

    		}
    		select {
    		case <-removedChan:
    			t.Fatal("Add() failed: callback invoked with added=false")
    		default:
    		}
    
    		wantEvent := fsnotify.Event{Name: file, Op: fsnotify.Write}
    		fakeWatcher.InjectEvent(file, wantEvent)
    		gotEvent := <-watcher.Events(file)
    		if gotEvent != wantEvent {
    			t.Fatalf("Events() failed: got %v want %v", gotEvent, wantEvent)
    		}
    
    		wantError := fmt.Errorf("error=%v", file)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 24 14:06:41 UTC 2023
    - 3.8K bytes
    - Viewed (0)
  3. pkg/filewatcher/fakefilewatcher.go

    type FakeWatcher struct {
    	sync.Mutex
    
    	events      map[string]chan fsnotify.Event
    	errors      map[string]chan error
    	changedFunc func(path string, added bool)
    }
    
    // InjectEvent injects an event into the fake file watcher.
    func (w *FakeWatcher) InjectEvent(path string, event fsnotify.Event) {
    	w.Lock()
    	ch, ok := w.events[path]
    	w.Unlock()
    
    	if ok {
    		ch <- event
    	}
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 24 14:06:41 UTC 2023
    - 3.6K bytes
    - Viewed (0)
Back to top