Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ PROOF_*.md
REQPROOF_*.md
proof-ux-log.md
PROOF_UNDER_MODELED_REQUIREMENTS_PROPOSAL.md
fuzz_results/
testdata/fuzz/
3 changes: 3 additions & 0 deletions benchmark/benchmark_delete_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (

// Verifies: STK-REQ-005
// MCDC STK-REQ-005: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDeleteSmall(b *testing.B) {
b.ReportAllocs()
b.ResetTimer()
Expand All @@ -19,6 +20,7 @@ func BenchmarkDeleteSmall(b *testing.B) {

// Verifies: STK-REQ-005
// MCDC STK-REQ-005: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDeleteNested(b *testing.B) {
b.ReportAllocs()
b.ResetTimer()
Expand All @@ -30,6 +32,7 @@ func BenchmarkDeleteNested(b *testing.B) {

// Verifies: STK-REQ-005
// MCDC STK-REQ-005: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDeleteLarge(b *testing.B) {
b.ReportAllocs()
b.ResetTimer()
Expand Down
6 changes: 6 additions & 0 deletions benchmark/benchmark_large_payload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import (
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
jsonparser.ArrayEach(largeFixture, func(value []byte, dataType jsonparser.ValueType, offset int, err error) {
Expand All @@ -51,6 +52,7 @@ func BenchmarkJsonParserLarge(b *testing.B) {
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonStructLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
var data LargePayload
Expand All @@ -72,6 +74,7 @@ func BenchmarkEncodingJsonStructLarge(b *testing.B) {
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonInterfaceLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
var data interface{}
Expand Down Expand Up @@ -100,6 +103,7 @@ func BenchmarkEncodingJsonInterfaceLarge(b *testing.B) {
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkFFJsonLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
var data LargePayload
Expand All @@ -124,6 +128,7 @@ func BenchmarkFFJsonLarge(b *testing.B) {
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEasyJsonLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
lexer := &jlexer.Lexer{Data: largeFixture}
Expand All @@ -149,6 +154,7 @@ func BenchmarkEasyJsonLarge(b *testing.B) {
// MCDC STK-REQ-003: N/A
// Verifies: STK-REQ-004
// MCDC STK-REQ-004: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDjsonLarge(b *testing.B) {
for i := 0; i < b.N; i++ {
m, _ := djson.DecodeObject(largeFixture)
Expand Down
15 changes: 15 additions & 0 deletions benchmark/benchmark_medium_payload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import (
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
jsonparser.Get(mediumFixture, "person", "name", "fullName")
Expand All @@ -58,6 +59,7 @@ func BenchmarkJsonParserMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserDeleteMedium(b *testing.B) {
fixture := make([]byte, 0, len(mediumFixture))
b.ResetTimer()
Expand All @@ -81,6 +83,7 @@ func BenchmarkJsonParserDeleteMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserEachKeyManualMedium(b *testing.B) {
paths := [][]string{
[]string{"person", "name", "fullName"},
Expand Down Expand Up @@ -117,6 +120,7 @@ func BenchmarkJsonParserEachKeyManualMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserEachKeyStructMedium(b *testing.B) {
paths := [][]string{
[]string{"person", "name", "fullName"},
Expand Down Expand Up @@ -165,6 +169,7 @@ func BenchmarkJsonParserEachKeyStructMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserObjectEachStructMedium(b *testing.B) {
nameKey, githubKey, gravatarKey := []byte("name"), []byte("github"), []byte("gravatar")
errStop := errors.New("stop")
Expand Down Expand Up @@ -224,6 +229,7 @@ func BenchmarkJsonParserObjectEachStructMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonStructMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
var data MediumPayload
Expand All @@ -247,6 +253,7 @@ func BenchmarkEncodingJsonStructMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonInterfaceMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
var data interface{}
Expand Down Expand Up @@ -280,6 +287,7 @@ func BenchmarkEncodingJsonInterfaceMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkGabsMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := gabs.ParseJSON(mediumFixture)
Expand Down Expand Up @@ -311,6 +319,7 @@ func BenchmarkGabsMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkGoSimpleJsonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := simplejson.NewJson(mediumFixture)
Expand Down Expand Up @@ -339,6 +348,7 @@ func BenchmarkGoSimpleJsonMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkFFJsonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
var data MediumPayload
Expand All @@ -365,6 +375,7 @@ func BenchmarkFFJsonMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJasonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := jason.NewObjectFromBytes(mediumFixture)
Expand Down Expand Up @@ -395,6 +406,7 @@ func BenchmarkJasonMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkUjsonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := ujson.NewFromBytes(mediumFixture)
Expand Down Expand Up @@ -427,6 +439,7 @@ func BenchmarkUjsonMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDjsonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
m, _ := djson.DecodeObject(mediumFixture)
Expand Down Expand Up @@ -457,6 +470,7 @@ func BenchmarkDjsonMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkUgirjiMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
decoder := codec.NewDecoderBytes(mediumFixture, new(codec.JsonHandle))
Expand Down Expand Up @@ -485,6 +499,7 @@ func BenchmarkUgirjiMedium(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEasyJsonMedium(b *testing.B) {
for i := 0; i < b.N; i++ {
lexer := &jlexer.Lexer{Data: mediumFixture}
Expand Down
1 change: 1 addition & 0 deletions benchmark/benchmark_set_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (

// Verifies: STK-REQ-005
// MCDC STK-REQ-005: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkSetLarge(b *testing.B) {
b.ReportAllocs()

Expand Down
18 changes: 18 additions & 0 deletions benchmark/benchmark_small_payload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import (

// Just for emulating field access, so it will not throw "evaluated but not used"
// Benchmark helper for STK-REQ-001, STK-REQ-003, STK-REQ-004, STK-REQ-005, and STK-REQ-007.
// reqproof:proptest:skip no-op benchmark helper; performs no work, returns immediately, no behavioral variance to property-test
func nothing(_ ...interface{}) {}

/*
Expand All @@ -39,6 +40,7 @@ func nothing(_ ...interface{}) {}
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
jsonparser.Get(smallFixture, "uuid")
Expand All @@ -60,6 +62,7 @@ func BenchmarkJsonParserSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserEachKeyManualSmall(b *testing.B) {
paths := [][]string{
[]string{"uuid"},
Expand Down Expand Up @@ -94,6 +97,7 @@ func BenchmarkJsonParserEachKeyManualSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserEachKeyStructSmall(b *testing.B) {
paths := [][]string{
[]string{"uuid"},
Expand Down Expand Up @@ -134,6 +138,7 @@ func BenchmarkJsonParserEachKeyStructSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserObjectEachStructSmall(b *testing.B) {
uuidKey, tzKey, uaKey, stKey := []byte("uuid"), []byte("tz"), []byte("ua"), []byte("st")
errStop := errors.New("stop")
Expand Down Expand Up @@ -182,6 +187,7 @@ func BenchmarkJsonParserObjectEachStructSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserSetSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
jsonparser.Set(smallFixture, []byte(`"c90927dd-1588-4fe7-a14f-8a8950cfcbd8"`), "uuid")
Expand All @@ -203,6 +209,7 @@ func BenchmarkJsonParserSetSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJsonParserDelSmall(b *testing.B) {
fixture := make([]byte, 0, len(smallFixture))
b.ResetTimer()
Expand Down Expand Up @@ -230,6 +237,7 @@ func BenchmarkJsonParserDelSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonStructSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
var data SmallPayload
Expand All @@ -249,6 +257,7 @@ func BenchmarkEncodingJsonStructSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEncodingJsonInterfaceSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
var data interface{}
Expand All @@ -272,6 +281,7 @@ func BenchmarkEncodingJsonInterfaceSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkGabsSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := gabs.ParseJSON(smallFixture)
Expand All @@ -298,6 +308,7 @@ func BenchmarkGabsSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkGoSimplejsonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := simplejson.NewJson(smallFixture)
Expand All @@ -321,6 +332,7 @@ func BenchmarkGoSimplejsonSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkGoSimplejsonSetSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := simplejson.NewJson(smallFixture)
Expand All @@ -347,6 +359,7 @@ func BenchmarkGoSimplejsonSetSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkFFJsonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
var data SmallPayload
Expand All @@ -369,6 +382,7 @@ func BenchmarkFFJsonSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkJasonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := jason.NewObjectFromBytes(smallFixture)
Expand All @@ -395,6 +409,7 @@ func BenchmarkJasonSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkUjsonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
json, _ := ujson.NewFromBytes(smallFixture)
Expand All @@ -421,6 +436,7 @@ func BenchmarkUjsonSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkDjsonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
m, _ := djson.DecodeObject(smallFixture)
Expand All @@ -441,6 +457,7 @@ func BenchmarkDjsonSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkUgirjiSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
decoder := codec.NewDecoderBytes(smallFixture, new(codec.JsonHandle))
Expand All @@ -464,6 +481,7 @@ func BenchmarkUgirjiSmall(b *testing.B) {
// MCDC STK-REQ-005: N/A
// Verifies: STK-REQ-007
// MCDC STK-REQ-007: N/A
// reqproof:proptest:skip performance benchmark; measures wall-clock time and allocations, output is non-deterministic and not comparable to an independent reference
func BenchmarkEasyJsonSmall(b *testing.B) {
for i := 0; i < b.N; i++ {
lexer := &jlexer.Lexer{Data: smallFixture}
Expand Down
Loading
Loading