-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Several more test cases, disable most of encoding/cue
- Loading branch information
sam boyer
committed
May 2, 2023
1 parent
9cda1a6
commit eff90d0
Showing
14 changed files
with
649 additions
and
384 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,6 @@ linters: | |
- dogsled | ||
- errcheck | ||
- exportloopref | ||
- funlen | ||
- gochecknoinits | ||
- gocritic | ||
- goconst | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,11 @@ | ||
package cue | ||
|
||
import ( | ||
"testing" | ||
|
||
"cuelang.org/go/cue/cuecontext" | ||
"github.com/grafana/thema" | ||
"github.com/grafana/thema/exemplars" | ||
) | ||
|
||
var ctx = cuecontext.New() | ||
var rt = thema.NewRuntime(ctx) | ||
|
||
func TestDoSimpleGenLineage(t *testing.T) { | ||
cuestr := ` | ||
foo: string | ||
bar: int | ||
` | ||
v := ctx.CompileString(cuestr) | ||
|
||
f, err := NewLineage(v, "somelineage", "testpkg") | ||
if err != nil { | ||
t.Fatal(err) | ||
} | ||
_ = f | ||
// fmt.Println(string(astutil.FmtNode(f))) | ||
} | ||
|
||
func TestSimpleAppendLineage(t *testing.T) { | ||
lin, _ := exemplars.NarrowingLineage(rt) | ||
|
||
cuestr := ` | ||
properbool: bool | ||
foo?: int | ||
` | ||
v := ctx.CompileString(cuestr) | ||
|
||
f, err := Append(lin, v) | ||
if err != nil { | ||
t.Fatal(err) | ||
} | ||
_ = f | ||
// fmt.Println(string(astutil.FmtNodeP(f))) | ||
} | ||
// TODO rewrite everything here on top of the corpus |
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.
Oops, something went wrong.