- Sort Score
- Result 10 results
- Languages All
Results 141 - 150 of 228 for mkdtemp (0.34 sec)
-
pkg/kubelet/cm/dra/plugin/client_test.go
return err } return nil } type tearDown func() func setupFakeGRPCServer(version string) (string, tearDown, error) { p, err := os.MkdirTemp("", "dra_plugin") if err != nil { return "", nil, err } closeCh := make(chan struct{}) addr := filepath.Join(p, "server.sock") teardown := func() { close(closeCh) os.RemoveAll(addr) }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Apr 19 16:27:05 UTC 2024 - 8.1K bytes - Viewed (0) -
pkg/kubelet/cm/container_manager_linux_test.go
} func TestSoftRequirementsValidationSuccess(t *testing.T) { if cgroups.IsCgroup2UnifiedMode() { t.Skip("skipping cgroup v1 test on a cgroup v2 system") } req := require.New(t) tempDir, err := os.MkdirTemp("", "") req.NoError(err) defer os.RemoveAll(tempDir) req.NoError(os.WriteFile(path.Join(tempDir, "cpu.cfs_period_us"), []byte("0"), os.ModePerm))
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Mar 07 08:12:16 UTC 2024 - 9.7K bytes - Viewed (0) -
src/cmd/cgo/internal/testsanitizers/cc_test.go
var cLibFuzzerInput = []byte(` #include <stddef.h> int LLVMFuzzerTestOneInput(char *data, size_t size) { return 0; } `) func (c *config) checkCSanitizer() (skip bool, err error) { dir, err := os.MkdirTemp("", c.sanitizer) if err != nil { return false, fmt.Errorf("failed to create temp directory: %v", err) } defer os.RemoveAll(dir) src := filepath.Join(dir, "return0.c") cInput := cMain
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 09 20:00:56 UTC 2024 - 14.4K bytes - Viewed (0) -
cluster/gce/gci/audit_policy_test.go
) func init() { // Register audit scheme to parse audit config. auditinstall.Install(auditpkg.Scheme) } func TestCreateMasterAuditPolicy(t *testing.T) { baseDir, err := os.MkdirTemp("", "configure-helper-test") // cleaned up by c.tearDown() require.NoError(t, err, "Failed to create temp directory") policyFile := filepath.Join(baseDir, "audit_policy.yaml") c := ManifestTestCase{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Oct 30 06:23:50 UTC 2021 - 9.8K bytes - Viewed (0) -
cmd/kubeadm/app/cmd/reset_test.go
certificatesDir: /etc/kubernetes/pki2 ignorePreflightErrors: - a - b `, kubeadmapiv1.SchemeGroupVersion.String(), defaultURLScheme) func TestNewResetData(t *testing.T) { // create temp directory tmpDir, err := os.MkdirTemp("", "kubeadm-reset-test") if err != nil { t.Errorf("Unable to create temporary directory: %v", err) } defer os.RemoveAll(tmpDir) // create config file
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Mar 26 13:42:50 UTC 2024 - 8.5K bytes - Viewed (0) -
src/cmd/cover/html.go
Name: fn, Body: template.HTML(buf.String()), Coverage: percentCovered(profile), }) } var out *os.File if outfile == "" { var dir string dir, err = os.MkdirTemp("", "cover") if err != nil { return err } out, err = os.Create(filepath.Join(dir, "coverage.html")) } else { out, err = os.Create(outfile) } if err != nil { return err }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Sep 08 14:33:36 UTC 2022 - 6.8K bytes - Viewed (0) -
src/cmd/go/scriptconds_test.go
return false, nil } } return false, fmt.Errorf("unrecognized GOEXPERIMENT %q", value) } func isCaseSensitive() (bool, error) { tmpdir, err := os.MkdirTemp(testTmpDir, "case-sensitive") if err != nil { return false, fmt.Errorf("failed to create directory to determine case-sensitivity: %w", err) } defer os.RemoveAll(tmpdir) fcap := filepath.Join(tmpdir, "FILE")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Feb 21 22:16:54 UTC 2024 - 7.4K bytes - Viewed (0) -
src/text/template/examplefiles_test.go
// templateFile defines the contents of a template to be stored in a file, for testing. type templateFile struct { name string contents string } func createTestDir(files []templateFile) string { dir, err := os.MkdirTemp("", "template") if err != nil { log.Fatal(err) } for _, file := range files { f, err := os.Create(filepath.Join(dir, file.name)) if err != nil { log.Fatal(err) } defer f.Close()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Dec 09 19:12:23 UTC 2020 - 6.1K bytes - Viewed (0) -
src/cmd/compile/internal/ssa/debug_lines_test.go
} func compileAndDump(t *testing.T, file, function, moreGCFlags string) []byte { testenv.MustHaveGoBuild(t) tmpdir, err := os.MkdirTemp("", "debug_lines_test") if err != nil { panic(fmt.Sprintf("Problem creating TempDir, error %v", err)) } if testing.Verbose() { fmt.Printf("Preserving temporary directory %s\n", tmpdir) } else {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Nov 21 20:24:52 UTC 2023 - 8.4K bytes - Viewed (0) -
staging/src/k8s.io/apiextensions-apiserver/pkg/cmd/server/testing/testserver.go
} } if len(result.TmpDir) != 0 { os.RemoveAll(result.TmpDir) } } defer func() { if result.TearDownFn == nil { tearDown() } }() result.TmpDir, err = os.MkdirTemp("", "apiextensions-apiserver") if err != nil { return result, fmt.Errorf("failed to create temp dir: %v", err) } fs := pflag.NewFlagSet("test", pflag.PanicOnError)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Apr 29 18:59:21 UTC 2024 - 9K bytes - Viewed (1)