-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into opentelemetry-exporter
- Loading branch information
Showing
29 changed files
with
1,216 additions
and
218 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package internal_test | ||
|
||
import ( | ||
"os" | ||
"testing" | ||
|
||
"go.opentelemetry.io/otel/api/global/internal" | ||
ottest "go.opentelemetry.io/otel/internal/testing" | ||
) | ||
|
||
// Ensure struct alignment prior to running tests. | ||
func TestMain(m *testing.M) { | ||
fieldsMap := internal.AtomicFieldOffsets() | ||
fields := make([]ottest.FieldOffset, 0, len(fieldsMap)) | ||
for name, offset := range fieldsMap { | ||
fields = append(fields, ottest.FieldOffset{ | ||
Name: name, | ||
Offset: offset, | ||
}) | ||
} | ||
if !ottest.Aligned8Byte(fields, os.Stderr) { | ||
os.Exit(1) | ||
} | ||
|
||
os.Exit(m.Run()) | ||
} |
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
Oops, something went wrong.