Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Kirill Smelkov
neo
Commits
fca52539
Commit
fca52539
authored
Jan 03, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
2e7f299e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
9 deletions
+4
-9
go/internal/xtracing/tracetest/example_test.go
go/internal/xtracing/tracetest/example_test.go
+3
-3
go/internal/xtracing/tracetest/tracetest.go
go/internal/xtracing/tracetest/tracetest.go
+1
-6
No files found.
go/internal/xtracing/tracetest/example_test.go
View file @
fca52539
// Copyright (C) 2018-202
0
Nexedi SA and Contributors.
// Copyright (C) 2018-202
1
Nexedi SA and Contributors.
// Kirill Smelkov <kirr@nexedi.com>
//
// This program is free software: you can Use, Study, Modify and Redistribute
...
...
@@ -111,7 +111,7 @@ func verify(t *testing.T, f func(t *tracetest.T), targvExtra ...string) {
// Test2ThreadsOK demonstrates verifying 2 threads that execute independently.
// There is no concurreny problem here.
// There is no concurren
c
y problem here.
func
Test2ThreadsOK
(
t
*
testing
.
T
)
{
verify
(
t
,
func
(
t
*
tracetest
.
T
)
{
var
wg
sync
.
WaitGroup
...
...
@@ -224,7 +224,7 @@ func TestExpectValue(t *testing.T) {
// ----------------------------------------
// verifyInSubprocess runs f in subprocess and verifies that its output matches test
Output
.
// verifyInSubprocess runs f in subprocess and verifies that its output matches test
ExpectMap[t.Name]
.
func
verifyInSubprocess
(
t
*
testing
.
T
,
f
func
(
t
*
testing
.
T
),
targvExtra
...
string
)
{
t
.
Helper
()
if
os
.
Getenv
(
"TRACETEST_EX_VERIFY_IN_SUBPROCESS"
)
==
"1"
{
...
...
go/internal/xtracing/tracetest/tracetest.go
View file @
fca52539
...
...
@@ -70,12 +70,7 @@
// XXX link to example.
//
//
// XXX say that checker will detect deadlock if there is no event or it or
// another comes at different trace channel.
//
// XXX (if tested system is serial only there is no need to use Dispatcher and
// routing - the collector can send output directly to the only Chan with
// only one EventChecker connected to it).
// XXX say that deadlocks are detected?
package
tracetest
import
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment