Update analyzer tests accordingly
This commit is contained in:
parent
3485fa1820
commit
7bad3d5672
|
@ -327,7 +327,7 @@ testStringErr (test,
|
||||||
"cannot assign to constant", 5, 2,
|
"cannot assign to constant", 5, 2,
|
||||||
`
|
`
|
||||||
T: Int
|
T: Int
|
||||||
| x 0
|
| x = 0
|
||||||
[main] = {
|
[main] = {
|
||||||
T.x = 5
|
T.x = 5
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,13 +6,13 @@ func TestConstantValueSpecified (test *testing.T) {
|
||||||
testString (test,
|
testString (test,
|
||||||
`
|
`
|
||||||
Weekday: Int
|
Weekday: Int
|
||||||
| sunday 1
|
| sunday = 1
|
||||||
| monday 2
|
| monday = 2
|
||||||
| tuesday 3
|
| tuesday = 3
|
||||||
| wednesday 4
|
| wednesday = 4
|
||||||
| thursday 5
|
| thursday = 5
|
||||||
| friday 6
|
| friday = 6
|
||||||
| saturday 7
|
| saturday = 7
|
||||||
|
|
||||||
[printWeekday w:Weekday]
|
[printWeekday w:Weekday]
|
||||||
[f] = [printWeekday Weekday.monday]
|
[f] = [printWeekday Weekday.monday]
|
||||||
|
@ -38,13 +38,13 @@ func TestConstantString (test *testing.T) {
|
||||||
testString (test,
|
testString (test,
|
||||||
`
|
`
|
||||||
Weekday: String
|
Weekday: String
|
||||||
| sunday 'sunday'
|
| sunday = 'sunday'
|
||||||
| monday 'monday'
|
| monday = 'monday'
|
||||||
| tuesday 'tuesday'
|
| tuesday = 'tuesday'
|
||||||
| wednesday 'wednesday'
|
| wednesday = 'wednesday'
|
||||||
| thursday 'thursday'
|
| thursday = 'thursday'
|
||||||
| friday 'friday'
|
| friday = 'friday'
|
||||||
| saturday 'saturday'
|
| saturday = 'saturday'
|
||||||
|
|
||||||
[print s:String]
|
[print s:String]
|
||||||
[printWeekday w:Weekday] = [print [~String w]]
|
[printWeekday w:Weekday] = [print [~String w]]
|
||||||
|
|
|
@ -209,13 +209,13 @@ testStringErr (test,
|
||||||
"no constant Weekday.palday", 13, 21,
|
"no constant Weekday.palday", 13, 21,
|
||||||
`
|
`
|
||||||
Weekday: String
|
Weekday: String
|
||||||
| sunday 'sunday'
|
| sunday = 'sunday'
|
||||||
| monday 'monday'
|
| monday = 'monday'
|
||||||
| tuesday 'tuesday'
|
| tuesday = 'tuesday'
|
||||||
| wednesday 'wednesday'
|
| wednesday = 'wednesday'
|
||||||
| thursday 'thursday'
|
| thursday = 'thursday'
|
||||||
| friday 'friday'
|
| friday = 'friday'
|
||||||
| saturday 'saturday'
|
| saturday = 'saturday'
|
||||||
|
|
||||||
[print s:String]
|
[print s:String]
|
||||||
[printWeekday w:Weekday] = [print [~String w]]
|
[printWeekday w:Weekday] = [print [~String w]]
|
||||||
|
@ -227,12 +227,12 @@ testStringErr (test,
|
||||||
"tuesday already defined at stream0.fspl:5:1", 8, 1,
|
"tuesday already defined at stream0.fspl:5:1", 8, 1,
|
||||||
`
|
`
|
||||||
Weekday: String
|
Weekday: String
|
||||||
| sunday 'sunday'
|
| sunday = 'sunday'
|
||||||
| monday 'monday'
|
| monday = 'monday'
|
||||||
| tuesday 'tuesday'
|
| tuesday = 'tuesday'
|
||||||
| wednesday 'wednesday'
|
| wednesday = 'wednesday'
|
||||||
| thursday 'thursday'
|
| thursday = 'thursday'
|
||||||
| tuesday 'tuesday'
|
| tuesday = 'tuesday'
|
||||||
| friday 'friday'
|
| friday = 'friday'
|
||||||
| saturday 'saturday'
|
| saturday = 'saturday'
|
||||||
`)}
|
`)}
|
||||||
|
|
Loading…
Reference in New Issue