INNER CODE UNIT · Go

TestMergeAllowedFields

movio/bramble · auth_test.go:598

func TestMergeAllowedFields(t *testing.T) {
	tts := []struct {
		name     string
		in       []string
		expected string
	}{
		{
			name: "basic merge",
			in: []string{
				`{"movie": ["title", "releaseDate"]}`,
				`{"movie": ["cast", "length"]}`,
			},
			expected: `{"movie": ["title", "releaseDate", "cast", "length"]}`,
		},
		{
			name: "recursive merge",
			in: []string{
				`{"movie": {"cast": ["lastName"] }}`,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…