2 # Copyright (C) 2006-2007, Parrot Foundation.
7 t/pmc/lexinfo.t - test LexInfo PMC
12 % prove t/pmc/lexinfo.t
16 Tests the LexInfo PMC.
21 .include 'test_more.pir'
32 ok(0, "shouldn't be able to create a LexInfo without an initializer")
35 ok(1, "can't create a LexInfo without an initializer")
43 $P2 = new 'ParrotInterpreter'
45 $P2 = $P2.'get_lexinfo'()
46 $P2 = inspect $P2, 'symbols'
48 is($I0, 2, "correct number of symbol in introspection hash")
50 .local int have_a, have_b
54 if $S0 != "$a" goto not_a_1
57 if $S0 != "$b" goto not_b_1
62 if $S0 != "$a" goto not_a_2
65 if $S0 != "$b" goto not_b_2
69 is(have_a, 1, "$a symbol was in list")
70 is(have_b, 1, "$b symbol was in list")
75 # cperl-indent-level: 4
78 # vim: expandtab shiftwidth=4 ft=pir: