- Sort Score
- Result 10 results
- Languages All
Results 101 - 110 of 367 for tempdir (0.13 sec)
-
src/syscall/syscall_linux_test.go
// Copy the test binary to a location that a non-root user can read/execute // after we drop privileges tempDir, err := os.MkdirTemp("", "TestSyscallNoError") if err != nil { t.Fatalf("cannot create temporary directory: %v", err) } defer os.RemoveAll(tempDir) os.Chmod(tempDir, 0755) tmpBinary := filepath.Join(tempDir, filepath.Base(os.Args[0])) src, err := os.Open(os.Args[0]) if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 23K bytes - Viewed (0) -
cmd/kubeadm/app/preflight/checks_test.go
check: DirAvailableCheck{ Path: fileDir, }, expectedError: false, }, { name: "Directory exists and has something", check: DirAvailableCheck{ Path: os.TempDir(), // a directory was created previously in this test }, expectedError: true, }, { name: "Directory does not exist", check: DirAvailableCheck{ Path: "/does/not/exist", },
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 06:58:01 UTC 2024 - 33.5K bytes - Viewed (0) -
src/os/writeto_linux_test.go
called bool dstfd int srcfd int written int64 handled bool err error } func createTempFile(t *testing.T, size int64) (*File, []byte) { f, err := CreateTemp(t.TempDir(), "writeto-sendfile-to-socket") if err != nil { t.Fatalf("failed to create temporary file: %v", err) } t.Cleanup(func() { f.Close() }) randSeed := time.Now().Unix()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 18:12:56 UTC 2024 - 4K bytes - Viewed (0) -
src/cmd/covdata/tool_test.go
exe, err := os.Executable() if err != nil { t.Helper() t.Fatal(err) } return exe } // Top level tempdir for test. var testTempDir string // If set, this will preserve all the tmpdir files from the test run. var preserveTmp = flag.Bool("preservetmp", false, "keep tmpdir files for debugging") // TestMain used here so that we can leverage the test executable
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 20:46:32 UTC 2024 - 24.5K bytes - Viewed (0) -
pkg/wasm/cache_test.go
}, } for _, c := range cases { t.Run(c.name, func(t *testing.T) { tmpDir := t.TempDir() options := defaultOptions() if c.purgeInterval != 0 { options.PurgeInterval = c.purgeInterval } if c.wasmModuleExpiry != 0 { options.ModuleExpiry = c.wasmModuleExpiry } cache := NewLocalFileCache(tmpDir, options) cache.httpFetcher.initialBackoff = time.Microsecond
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Apr 17 20:06:41 UTC 2024 - 33.9K bytes - Viewed (0) -
pkg/test/framework/suite_test.go
return func(testID string) (*resource.Settings, error) { s.TestID = testID s.BaseDir = os.TempDir() return s, nil } } func defaultSettingsFn(testID string) (*resource.Settings, error) { s := resource.DefaultSettings() s.TestID = testID s.BaseDir = os.TempDir() return s, nil } func cleanupRT() { rtMu.Lock() defer rtMu.Unlock() rt = nil }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu Jun 06 22:12:34 UTC 2024 - 11.5K bytes - Viewed (0) -
pkg/test/framework/resource/flags.go
func init() { log.EnableKlogWithGoFlag() flag.StringVar(&settingsFromCommandLine.BaseDir, "istio.test.work_dir", os.TempDir(), "Local working directory for creating logs/temp files. If left empty, os.TempDir() is used.") var env string flag.StringVar(&env, "istio.test.env", "", "Deprecated. This flag does nothing")
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu May 09 19:04:51 UTC 2024 - 14K bytes - Viewed (0) -
src/runtime/debug/stack_test.go
} func TestSetCrashOutput(t *testing.T) { testenv.MustHaveExec(t) exe, err := os.Executable() if err != nil { t.Fatal(err) } crashOutput := filepath.Join(t.TempDir(), "crash.out") cmd := exec.Command(exe) cmd.Stderr = new(strings.Builder) cmd.Env = append(os.Environ(), "GO_RUNTIME_DEBUG_TEST_ENTRYPOINT=setcrashoutput", "CRASHOUTPUT="+crashOutput) err = cmd.Run()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 16 15:19:04 UTC 2024 - 5.5K bytes - Viewed (0) -
pkg/kubelet/nodeshutdown/nodeshutdown_manager_linux_test.go
ShutdownGracePeriodCriticalPods: tc.shutdownGracePeriodCriticalPods, Clock: testingclock.NewFakeClock(time.Now()), StateDirectory: os.TempDir(), }) err := manager.Start() lock.Unlock() if tc.expectedError != nil { if err == nil { t.Errorf("unexpected error message. Got: <nil> want %s", tc.expectedError.Error())
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 29.8K bytes - Viewed (0) -
platforms/jvm/jvm-services/src/test/groovy/org/gradle/internal/jvm/inspection/DefaultJvmMetadataDetectorTest.groovy
import org.spockframework.runtime.SpockAssertionError import spock.lang.Specification import spock.lang.TempDir class DefaultJvmMetadataDetectorTest extends Specification { @TempDir File temporaryFolder TestFile tmpDir def setup() { tmpDir = new TestFile(new File(temporaryFolder, "tmp").tap { mkdirs() }) } def "cleans up generated Probe class"() { given:
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Tue Mar 12 18:25:34 UTC 2024 - 22.9K bytes - Viewed (0)