Improve test coverage for testing AST
This commit is contained in:
parent
fd900ab8b2
commit
ff36ebcff2
|
@ -129,6 +129,10 @@ private:
|
|||
ASSERT_EQUALS(true, isReturnScope("auto f() { return [=]() { return data; }; }", -1));
|
||||
ASSERT_EQUALS(true, isReturnScope("auto f() { return [=]() { return data; }(); }", -1));
|
||||
ASSERT_EQUALS(false, isReturnScope("auto f() { [=]() { return data; }(); }", -1));
|
||||
|
||||
ASSERT_EQUALS(true, isReturnScope("void negativeTokenOffset() { return; }", -1));
|
||||
ASSERT_EQUALS(false, isReturnScope("void zeroTokenOffset() { return; }", 0));
|
||||
ASSERT_EQUALS(true, isReturnScope("void positiveTokenOffset() { return; }", 7));
|
||||
}
|
||||
|
||||
bool isVariableChanged(const char code[], const char startPattern[], const char endPattern[]) {
|
||||
|
|
Loading…
Reference in New Issue