Permalink
Browse files

Tweaks before release.

- Remove pytrace from unit test.  It was polluting the repo.  I saved
  this test case in my scratch repo.
- Comments about release process.
  • Loading branch information...
Andy Chu
Andy Chu committed Dec 10, 2017
1 parent 6593c24 commit a82dfbf881caa5b2e04c22ba67275ace67659611
Showing with 7 additions and 31 deletions.
  1. +4 −31 native/fastlex_test.py
  2. +3 −0 scripts/release.sh
View
@@ -58,40 +58,13 @@ def testOutOfBounds(self):
print MatchToken(lex_mode_e.OUTER, 'line', 5)
def testBug(self):
import os
pid = os.getpid()
# This changes the results! WTF!
from benchmarks import pytrace
t = pytrace.Tracer()
t.Start()
# woah this makes no sense
# expected 194, got 197. So how is expected being corrupted?
code_str = '-z'
expected = Id.BoolUnary_z
# expected 197 got 195 (but it says that is -n, which is 198)
code_str = '-v'
expected = Id.BoolUnary_v
# -n confused with -R
# 195 198
code_str = '-n'
expected = Id.BoolUnary_n
try:
tok_type, end_pos = MatchToken(lex_mode_e.DBRACKET, code_str, 0)
#print tok_type, end_pos
#print tok_type
print '---', 'expected', expected.enum_value, 'got', tok_type.enum_value
#print 'L', id(Id.BoolUnary_z)
#print 'L', id(Id.BoolUnary_z.enum_value)
self.assertEqual(expected, tok_type)
#self.assertEqual(2, end_pos, Id.BoolUnary_z)
finally:
t.Stop('bug-%d.pytrace' % pid)
tok_type, end_pos = MatchToken(lex_mode_e.DBRACKET, code_str, 0)
print '---', 'expected', expected.enum_value, 'got', tok_type.enum_value
self.assertEqual(expected, tok_type)
if __name__ == '__main__':
View
@@ -6,8 +6,11 @@
# Steps:
# build/doc.sh update-src-versions (optional)
# $0 build-and-test (runs spec tests, etc.)
# prereq: build/codegen.sh {download,install}-re2c
# test/wild.sh all
# benchmarks/auto.sh all on both flanders and lisa
# prereq: benchmarks/osh-runtime.sh {download,extract}
# benchmarks/oheap.sh measure
# benchmarks/report.sh all
# $0 line-counts
# $0 build-tree

0 comments on commit a82dfbf

Please sign in to comment.