Skip to content

Commit

Permalink
{test} Rename examples so they sort better in the documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
asmaloney committed Feb 1, 2024
1 parent 847595f commit 563df3a
Show file tree
Hide file tree
Showing 5 changed files with 68 additions and 68 deletions.
42 changes: 21 additions & 21 deletions amod/amod_config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ func Example_gactarAllOptions() {
// Output:
}

func Example_gactarUnrecognizedField() {
func Example_gactarErrorUnrecognizedField() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -28,7 +28,7 @@ func Example_gactarUnrecognizedField() {
// ERROR: unrecognized option "foo" in gactar section (line 5, col 10)
}

func Example_gactarUnrecognizedLogLevel() {
func Example_gactarErrorUnrecognizedLogLevel() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -41,7 +41,7 @@ func Example_gactarUnrecognizedLogLevel() {
// ERROR: 'log_level' invalid type (found id; expected string) (line 5, col 21)
}

func Example_gactarUnrecognizedNestedValue() {
func Example_gactarErrorUnrecognizedNestedValue() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -54,7 +54,7 @@ func Example_gactarUnrecognizedNestedValue() {
// ERROR: unrecognized option "foo" in gactar section (line 5, col 10)
}

func Example_gactarFieldNotANestedValue() {
func Example_gactarErrorFieldNotANestedValue() {
generateToStdout(`
~~ model ~~
name: Test
Expand Down Expand Up @@ -91,7 +91,7 @@ func Example_gactarTraceActivations() {
// Output:
}

func Example_gactarTraceActivationsNonBool() {
func Example_gactarErrorTraceActivationsNonBool() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -104,7 +104,7 @@ func Example_gactarTraceActivationsNonBool() {
// ERROR: 'trace_activations' invalid type (found number; expected true or false) (line 5, col 29)
}

func Example_chunkInternalType() {
func Example_chunkErrorInternalType() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -117,7 +117,7 @@ func Example_chunkInternalType() {
// ERROR: cannot use reserved chunk type "_internal" (chunks beginning with '_' are reserved) (line 5, col 11)
}

func Example_chunkReservedType() {
func Example_chunkErrorReservedType() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -130,7 +130,7 @@ func Example_chunkReservedType() {
// ERROR: cannot use reserved chunk type "requested" (line 5, col 11)
}

func Example_chunkDuplicateType() {
func Example_chunkErrorDuplicateType() {
generateToStdout(`
~~ model ~~
name: Test
Expand Down Expand Up @@ -177,7 +177,7 @@ func Example_modulesExtraBuffers() {
// Output:
}

func Example_modulesExtraBuffersDuplicate() {
func Example_modulesErrorExtraBuffersDuplicate() {
generateToStdout(`
~~ model ~~
name: Test
Expand Down Expand Up @@ -212,7 +212,7 @@ func Example_modulesInitBuffer() {
// Output:
}

func Example_modulesInitBufferNoMaxSpread() {
func Example_modulesErrorInitBufferNoMaxSpread() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -229,7 +229,7 @@ func Example_modulesInitBufferNoMaxSpread() {
// ERROR: spreading_activation set on buffer "imaginal", but max_spread_strength not set on memory module (line 5, col 1)
}

func Example_modulesInitBufferDuplicate() {
func Example_modulesErrorInitBufferDuplicate() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -250,7 +250,7 @@ func Example_modulesInitBufferDuplicate() {
// ERROR: duplicate option "spreading_activation" (line 10, col 4)
}

func Example_modulesUnrecognizedModule() {
func Example_modulesErrorUnrecognizedModule() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -265,7 +265,7 @@ func Example_modulesUnrecognizedModule() {
// ERROR: unrecognized module in config: 'foo' (line 6, col 2)
}

func Example_modulesUnrecognizedModuleOption() {
func Example_modulesErrorUnrecognizedModuleOption() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -280,7 +280,7 @@ func Example_modulesUnrecognizedModuleOption() {
// ERROR: unrecognized option "foo" in goal config (line 6, col 9)
}

func Example_modulesUnrecognizedModuleDuplicateOption() {
func Example_modulesErrorUnrecognizedModuleDuplicateOption() {
generateToStdout(`
~~ model ~~
name: Test
Expand Down Expand Up @@ -353,7 +353,7 @@ func Example_imaginalFields() {
// Output:
}

func Example_imaginalFieldType() {
func Example_imaginalErrorFieldType() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -368,7 +368,7 @@ func Example_imaginalFieldType() {
// ERROR: imaginal "delay" invalid type (found string; expected number) (line 6, col 20)
}

func Example_imaginalFieldRange() {
func Example_imaginalErrorFieldRange() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -383,7 +383,7 @@ func Example_imaginalFieldRange() {
// ERROR: imaginal "delay" is out of range (minimum 0) (line 6, col 20)
}

func Example_imaginalFieldUnrecognized() {
func Example_imaginalErrorFieldUnrecognized() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -398,7 +398,7 @@ func Example_imaginalFieldUnrecognized() {
// ERROR: unrecognized option "foo" in imaginal config (line 6, col 13)
}

func Example_memoryFieldUnrecognized() {
func Example_memoryErrorFieldUnrecognized() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -413,7 +413,7 @@ func Example_memoryFieldUnrecognized() {
// ERROR: unrecognized option "foo" in memory config (line 6, col 11)
}

func Example_memoryDecayOutOfRange() {
func Example_memoryErrorDecayOutOfRange() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -428,7 +428,7 @@ func Example_memoryDecayOutOfRange() {
// ERROR: memory "decay" is out of range (0-1) (line 6, col 18)
}

func Example_memoryDecayOutOfRange2() {
func Example_memoryErrorDecayOutOfRange2() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -443,7 +443,7 @@ func Example_memoryDecayOutOfRange2() {
// ERROR: memory "decay" is out of range (0-1) (line 6, col 18)
}

func Example_proceduralFieldUnrecognized() {
func Example_proceduralErrorFieldUnrecognized() {
generateToStdout(`
~~ model ~~
name: Test
Expand Down
14 changes: 7 additions & 7 deletions amod/amod_init_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ func Example_initializer6() {
// Output:
}

func Example_initializerInvalidSlots() {
func Example_initializerErrorInvalidSlots() {
// Check invalid number of slots in init
generateToStdout(`
~~ model ~~
Expand All @@ -114,7 +114,7 @@ func Example_initializerInvalidSlots() {
// ERROR: invalid chunk - 'author' expects 3 slots (line 7, col 10)
}

func Example_initializerInvalidChunk1() {
func Example_initializerErrorInvalidChunk1() {
// Check memory with invalid chunk
generateToStdout(`
~~ model ~~
Expand All @@ -128,7 +128,7 @@ func Example_initializerInvalidChunk1() {
// ERROR: could not find chunk named 'author' (line 6, col 11)
}

func Example_initializerInvalidChunk2() {
func Example_initializerErrorInvalidChunk2() {
// Check buffer with invalid chunk
generateToStdout(`
~~ model ~~
Expand All @@ -142,7 +142,7 @@ func Example_initializerInvalidChunk2() {
// ERROR: could not find chunk named 'author' (line 6, col 7)
}

func Example_initializerUnknownBuffer() {
func Example_initializerErrorUnknownBuffer() {
// Check unknown buffer
generateToStdout(`
~~ model ~~
Expand All @@ -157,7 +157,7 @@ func Example_initializerUnknownBuffer() {
// ERROR: module 'something' not found in initialization (line 7, col 1)
}

func Example_initializerMultipleInits() {
func Example_initializerErrorMultipleInits() {
// Check buffer with multiple inits
generateToStdout(`
~~ model ~~
Expand Down Expand Up @@ -194,7 +194,7 @@ func Example_initializerMultipleBuffers() {
// Output:
}

func Example_initializerNoBuffers() {
func Example_initializerErrorNoBuffers() {
generateToStdout(`
~~ model ~~
name: Test
Expand All @@ -212,7 +212,7 @@ func Example_initializerNoBuffers() {
// ERROR: module 'extra_buffers' does not have any buffers (line 8, col 1)
}

func Example_initializerDuplicateNames() {
func Example_initializerErrorDuplicateNames() {
// memory with named chunks
generateToStdout(`
~~ model ~~
Expand Down
2 changes: 1 addition & 1 deletion amod/amod_model_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func Example_modelExamples() {
// Output:
}

func Example_modelExampleBadChunk() {
func Example_modelErrorExampleBadChunk() {
generateToStdout(`
~~ model~~
name: Test
Expand Down
Loading

0 comments on commit 563df3a

Please sign in to comment.