Skip to content

Commit ccba61a

Browse files
committed
add test for multiline template
1 parent a7fe119 commit ccba61a

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
template< typename T >
2+
T func(T t){
3+
return t * t;
4+
}
5+
6+
void setup() {
7+
func( 12.34f );
8+
}
9+
10+
void loop() {}

src/arduino.cc/builder/test/try_build_of_problematic_sketch_test.go

+4
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,10 @@ func TestTryBuild040(t *testing.T) {
209209
tryBuild(t, "sketch_with_externC_multiline", "sketch_with_externC_multiline.ino")
210210
}
211211

212+
func TestTryBuild041(t *testing.T) {
213+
tryBuild(t, "sketch_with_multiline_template", "sketch_with_multiline_template.ino")
214+
}
215+
212216
func makeDefaultContext(t *testing.T) *types.Context {
213217
DownloadCoresAndToolsAndLibraries(t)
214218

0 commit comments

Comments
 (0)