- Sort Score
- Result 10 results
- Languages All
Results 51 - 60 of 200 for ChDir (0.16 sec)
-
src/os/os_test.go
if err != nil { t.Fatalf("Getwd: %s", err) } defer Chdir(wd) fd, err := Open(".") if err != nil { t.Fatalf("Open .: %s", err) } defer fd.Close() if err := Chdir("/"); err != nil { t.Fatalf("Chdir /: %s", err) } if err := fd.Chdir(); err != nil { t.Fatalf("fd.Chdir: %s", err) } wdNew, err := Getwd() if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 83.1K bytes - Viewed (0) -
src/os/path_windows_test.go
testMkdirAllAtRoot(t, volName) } func TestRemoveAllLongPathRelative(t *testing.T) { // Test that RemoveAll doesn't hang with long relative paths. // See go.dev/issue/36375. tmp := t.TempDir() chdir(t, tmp) dir := filepath.Join(tmp, "foo", "bar", strings.Repeat("a", 150), strings.Repeat("b", 150)) err := os.MkdirAll(dir, 0755) if err != nil { t.Fatal(err) } err = os.RemoveAll("foo") if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 23 16:37:32 UTC 2024 - 8K bytes - Viewed (0) -
src/internal/testlog/log.go
// it is inspecting the given environment variables or files. // Multiple goroutines may call these methods simultaneously. type Interface interface { Getenv(key string) Stat(file string) Open(file string) Chdir(dir string) } // logger is the current logger Interface. // We use an atomic.Value in case test startup // is racing with goroutines started during init. // That must not cause a race detector failure,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Dec 11 19:08:32 UTC 2017 - 1.9K bytes - Viewed (0) -
tests/test_tutorial/test_sql_databases/test_sql_databases_py39.py
@pytest.fixture(scope="module", name="client") def get_client(tmp_path_factory: pytest.TempPathFactory): tmp_path = tmp_path_factory.mktemp("data") cwd = os.getcwd() os.chdir(tmp_path) test_db = Path("./sql_app.db") if test_db.is_file(): # pragma: nocover test_db.unlink() # Import while creating the client to create the DB after starting the test session
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Wed Mar 13 19:07:10 UTC 2024 - 16.5K bytes - Viewed (0) -
tests/test_tutorial/test_sql_databases/test_sql_databases.py
from ...utils import needs_pydanticv1 @pytest.fixture(scope="module") def client(tmp_path_factory: pytest.TempPathFactory): tmp_path = tmp_path_factory.mktemp("data") cwd = os.getcwd() os.chdir(tmp_path) test_db = Path("./sql_app.db") if test_db.is_file(): # pragma: nocover test_db.unlink() # Import while creating the client to create the DB after starting the test session
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Wed Mar 13 19:07:10 UTC 2024 - 16.1K bytes - Viewed (0) -
tests/test_tutorial/test_sql_databases/test_sql_databases_middleware_py310.py
from ...utils import needs_py310, needs_pydanticv1 @pytest.fixture(scope="module") def client(tmp_path_factory: pytest.TempPathFactory): tmp_path = tmp_path_factory.mktemp("data") cwd = os.getcwd() os.chdir(tmp_path) test_db = Path("./sql_app.db") if test_db.is_file(): # pragma: nocover test_db.unlink() # Import while creating the client to create the DB after starting the test session
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Wed Mar 13 19:07:10 UTC 2024 - 16.5K bytes - Viewed (0) -
pkg/bootstrap/config_test.go
t.Setenv(IstioMetaPrefix+"OWNER", inputOwner) t.Setenv(IstioMetaPrefix+"WORKLOAD_NAME", inputWorkloadName) dir, _ := os.Getwd() defer os.Chdir(dir) // prepare a pod label file tempDir := t.TempDir() os.Chdir(tempDir) os.MkdirAll("./etc/istio/pod/", os.ModePerm) os.WriteFile(constants.PodInfoLabelsPath, []byte(`istio-locality="region.zone.subzone"`), 0o600)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu Mar 28 20:38:02 UTC 2024 - 9.1K bytes - Viewed (0) -
src/syscall/fs_js.go
n = copy(buf, cwd) return } func Chdir(path string) (err error) { if err := checkPath(path); err != nil { return err } defer recoverErr(&err) jsProcess.Call("chdir", path) return } func Fchdir(fd int) error { f, err := fdToFile(fd) if err != nil { return err } return Chdir(f.path) } func Readlink(path string, buf []byte) (n int, err error) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 11 18:19:17 UTC 2023 - 10.8K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/sys/plan9/syscall_plan9.go
} if int32(r0) == -1 { err = e } return } func Fchdir(fd int) (err error) { path, err := Fd2path(fd) if err != nil { return } return Chdir(path) } type Timespec struct { Sec int32 Nsec int32 } type Timeval struct { Sec int32 Usec int32 } func NsecToTimeval(nsec int64) (tv Timeval) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 16 22:24:28 UTC 2022 - 7K bytes - Viewed (0) -
src/os/exec/lp_windows_test.go
files: []string{`p1\a.bat`, `p2\a.bat`}, PATH: []string{`.\p1`, `p1`, `p2`}, searchFor: `a`, want: `p1\a.bat`, }, } func TestLookPathWindows(t *testing.T) { // Not parallel: uses Chdir and Setenv. // We are using the "printpath" command mode to test exec.Command here, // so we won't be calling helperCommand to resolve it. // That may cause it to appear to be unused.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 13 19:38:12 UTC 2023 - 16.3K bytes - Viewed (0)