diff --git a/minifier.py b/minifier.py index a430d7c..9783330 100755 --- a/minifier.py +++ b/minifier.py @@ -19,7 +19,7 @@ def is_group_opening(self): def __eq__(self, other): if isinstance(other, BashFileIterator._Delimiter): return other.character == self.character - elif isinstance(other, basestring): + elif isinstance(other, str): return other == self.character return False @@ -213,7 +213,7 @@ def close_heredoc(): self.pos += 1 assert not self.isInsideGroup(), 'Invalid syntax' - raise StopIteration + # raise StopIteration # XXX I'm not too confident of the purpose of this, but it works without it. def isEscaped(self): return self.pos in self._indices_of_escaped_characters diff --git a/run_tests.sh b/run_tests.sh index 7a08616..01f35d9 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -5,7 +5,7 @@ passed=0 failed=0 for f in t*.sh; do echo -n "$f " - python ../minifier.py $f > _tmp_$f + python3 ../minifier.py $f > _tmp_$f if [ `diff _tmp_$f minified_$f | wc -c` -ne 0 ]; then failed=$((failed+1)) echo FAILED