forked from ruchee/vimrc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
168 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
47 changes: 47 additions & 0 deletions
47
vimfiles/bundle/vim-go/autoload/go/test-fixtures/test/src/timeout/timeout_test.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// Run a few parallel tests, all in parallel, using multiple techniques for | ||
// causing the test to take a while so that the stacktraces resulting from a | ||
// test timeout will contain several goroutines to avoid giving a false sense | ||
// of confidence or creating error formats that don't account for the more | ||
// complex scenarios that can occur with timeouts. | ||
|
||
package main | ||
|
||
import ( | ||
"testing" | ||
"time" | ||
) | ||
|
||
func TestSleep(t *testing.T) { | ||
t.Parallel() | ||
time.Sleep(15 * time.Second) | ||
t.Log("expected panic if run with timeout < 15s") | ||
} | ||
|
||
func TestRunning(t *testing.T) { | ||
t.Parallel() | ||
c := time.After(15 * time.Second) | ||
Loop: | ||
for { | ||
select { | ||
case <-c: | ||
break Loop | ||
default: | ||
} | ||
} | ||
|
||
t.Log("expected panic if run with timeout < 15s") | ||
} | ||
|
||
func TestRunningAlso(t *testing.T) { | ||
t.Parallel() | ||
c := time.After(15 * time.Second) | ||
Loop: | ||
for { | ||
select { | ||
case <-c: | ||
break Loop | ||
default: | ||
} | ||
} | ||
t.Log("expected panic if run with timeout < 15s") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.