mirror of https://github.com/rclone/rclone
fstest: add ResetRun to allow the remote to be reset in tests
This commit is contained in:
parent
459e10d599
commit
203df6cc58
|
|
@ -60,11 +60,16 @@ type Run struct {
|
|||
Logf, Fatalf func(text string, args ...any)
|
||||
}
|
||||
|
||||
// ResetRun re-reads the command line arguments into the global run.
|
||||
func ResetRun() {
|
||||
oneRun = newRun()
|
||||
}
|
||||
|
||||
// TestMain drives the tests
|
||||
func TestMain(m *testing.M) {
|
||||
flag.Parse()
|
||||
if !*Individual {
|
||||
oneRun = newRun()
|
||||
ResetRun()
|
||||
}
|
||||
rc := m.Run()
|
||||
if !*Individual {
|
||||
|
|
|
|||
Loading…
Reference in New Issue