forked from sourcenetwork/defradb
-
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.
test(i): Restructure mutation integration test dir (sourcenetwork#1848)
## Relevant issue(s) Resolves sourcenetwork#1847 ## Description Restructures mutation integration test dir. The previous structure did not offer adequate levels of test discoverability, and as we really need to add more tests here, it needed sorting out. Also, all tests (I think) in the `mutation` directory have been migrated to the newer test framework. A handful have been deleted, as the restructuring highlight a few duplicates. Some schemas have also been simplified.
- Loading branch information
1 parent
6bd4ee5
commit 8b10d0b
Showing
58 changed files
with
3,525 additions
and
2,864 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
54 changes: 54 additions & 0 deletions
54
tests/integration/mutation/create/field_kinds/one_to_one_to_one/utils.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,54 @@ | ||
// Copyright 2023 Democratized Data Foundation | ||
// | ||
// Use of this software is governed by the Business Source License | ||
// included in the file licenses/BSL.txt. | ||
// | ||
// As of the Change Date specified in that file, in accordance with | ||
// the Business Source License, use of this software will be governed | ||
// by the Apache License, Version 2.0, included in the file | ||
// licenses/APL.txt. | ||
|
||
package one_to_one_to_one | ||
|
||
import ( | ||
"testing" | ||
|
||
testUtils "github.com/sourcenetwork/defradb/tests/integration" | ||
) | ||
|
||
func execute(t *testing.T, test testUtils.TestCase) { | ||
testUtils.ExecuteTestCase( | ||
t, | ||
testUtils.TestCase{ | ||
Description: test.Description, | ||
Actions: append( | ||
[]any{ | ||
testUtils.SchemaUpdate{ | ||
Schema: ` | ||
type Book { | ||
name: String | ||
rating: Float | ||
author: Author | ||
publisher: Publisher | ||
} | ||
type Author { | ||
name: String | ||
age: Int | ||
verified: Boolean | ||
wrote: Book @primary | ||
} | ||
type Publisher { | ||
name: String | ||
address: String | ||
published: Book | ||
} | ||
`, | ||
}, | ||
}, | ||
test.Actions..., | ||
), | ||
}, | ||
) | ||
} |
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.