Selaa lähdekoodia

Tests: Fixed skipping nearley when it isn't included

gm/2021-09-23T00Z/github.com--lark-parser-lark/v0.12.0
Erez Sh 3 vuotta sitten
vanhempi
commit
b1103bdcf1
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. +2
    -2
      tests/test_nearley/test_nearley.py

+ 2
- 2
tests/test_nearley/test_nearley.py Näytä tiedosto

@@ -15,8 +15,8 @@ TEST_PATH = os.path.abspath(os.path.dirname(__file__))
NEARLEY_PATH = os.path.join(TEST_PATH, 'nearley')
BUILTIN_PATH = os.path.join(NEARLEY_PATH, 'builtin')

if not os.path.exists(NEARLEY_PATH):
logger.warn("Nearley not installed. Skipping Nearley tests!")
if not os.path.exists(BUILTIN_PATH):
logger.warn("Nearley not included. Skipping Nearley tests! (use git submodule to add)")
raise ImportError("Skipping Nearley tests!")

import js2py # Ensures that js2py exists, to avoid failing tests


Ladataan…
Peruuta
Tallenna