mirror of
https://github.com/github/semantic.git
synced 2024-12-24 23:42:31 +03:00
test less-copacetic cases
This commit is contained in:
parent
e05f419314
commit
5c8cd4a109
@ -35,3 +35,11 @@ spec = describe "call graphing" $ do
|
||||
res <- callGraphPythonProject ["test/fixtures/python/graphing/conditional/conditional.py"]
|
||||
unGraph res `shouldSatisfy` hasVertex (Variable "merle")
|
||||
unGraph res `shouldSatisfy` hasVertex (Variable "taako")
|
||||
|
||||
it "should continue even when a type error is encountered" $ do
|
||||
res <- callGraphPythonProject ["test/fixtures/python/graphing/typeerror/typeerror.py"]
|
||||
unGraph res `shouldSatisfy` hasVertex (Variable "lup")
|
||||
|
||||
it "should continue when an unbound variable is encountered" $ do
|
||||
res <- callGraphPythonProject ["test/fixtures/python/graphing/unbound/unbound.py"]
|
||||
unGraph res `shouldSatisfy` hasVertex (Variable "lucretia")
|
||||
|
5
test/fixtures/python/graphing/typeerror/typeerror.py
vendored
Normal file
5
test/fixtures/python/graphing/typeerror/typeerror.py
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
var = 1 + "thing"
|
||||
|
||||
def lup(): pass
|
||||
|
||||
lup()
|
5
test/fixtures/python/graphing/unbound/unbound.py
vendored
Normal file
5
test/fixtures/python/graphing/unbound/unbound.py
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
var = thing + 1
|
||||
|
||||
def lucretia(): pass
|
||||
|
||||
lucretia()
|
Loading…
Reference in New Issue
Block a user