mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-15 04:05:38 +02:00
Adjusted a test case for bug 268704.
This commit is contained in:
parent
084f3fbdef
commit
0105ad935d
1 changed files with 7 additions and 2 deletions
|
@ -1882,11 +1882,14 @@ public class IndexBugsTests extends BaseTestCase {
|
||||||
}
|
}
|
||||||
|
|
||||||
// // a.h
|
// // a.h
|
||||||
|
// namespace ns {
|
||||||
// struct A {
|
// struct A {
|
||||||
// int i;
|
// int i;
|
||||||
// };
|
// };
|
||||||
|
// }
|
||||||
|
|
||||||
// #include "a.h"
|
// #include "a.h"
|
||||||
|
// using ns::A;
|
||||||
// void test() {
|
// void test() {
|
||||||
// A a;
|
// A a;
|
||||||
// a.i = 0;
|
// a.i = 0;
|
||||||
|
@ -1904,7 +1907,7 @@ public class IndexBugsTests extends BaseTestCase {
|
||||||
// a.i = 0;
|
// a.i = 0;
|
||||||
// a.j = 0;
|
// a.j = 0;
|
||||||
// }
|
// }
|
||||||
public void _testDisambiguationByReachability_268685() throws Exception {
|
public void _testDisambiguationByReachability_268704_1() throws Exception {
|
||||||
waitForIndexer();
|
waitForIndexer();
|
||||||
|
|
||||||
String[] testData = getContentsForTest(4);
|
String[] testData = getContentsForTest(4);
|
||||||
|
@ -1919,9 +1922,11 @@ public class IndexBugsTests extends BaseTestCase {
|
||||||
index.acquireReadLock();
|
index.acquireReadLock();
|
||||||
try {
|
try {
|
||||||
BindingAssertionHelper aHelper = new BindingAssertionHelper(a, testData[1], index);
|
BindingAssertionHelper aHelper = new BindingAssertionHelper(a, testData[1], index);
|
||||||
|
aHelper.assertNonProblem("A a;", 1, ICPPVariable.class);
|
||||||
aHelper.assertNonProblem("i = 0;", 1, ICPPVariable.class);
|
aHelper.assertNonProblem("i = 0;", 1, ICPPVariable.class);
|
||||||
aHelper.assertProblem("j = 0;", 1);
|
aHelper.assertProblem("j = 0;", 1);
|
||||||
BindingAssertionHelper bHelper = new BindingAssertionHelper(b, testData[3], index);
|
BindingAssertionHelper bHelper = new BindingAssertionHelper(b, testData[3], index);
|
||||||
|
aHelper.assertNonProblem("A a;", 1, ICPPVariable.class);
|
||||||
bHelper.assertProblem("i = 0;", 1);
|
bHelper.assertProblem("i = 0;", 1);
|
||||||
bHelper.assertNonProblem("j = 0;", 1, ICPPVariable.class);
|
bHelper.assertNonProblem("j = 0;", 1, ICPPVariable.class);
|
||||||
} finally {
|
} finally {
|
||||||
|
@ -1943,7 +1948,7 @@ public class IndexBugsTests extends BaseTestCase {
|
||||||
|
|
||||||
// #include "b.h"
|
// #include "b.h"
|
||||||
// int i = e;
|
// int i = e;
|
||||||
public void _testDisambiguationByReachability_268704() throws Exception {
|
public void _testDisambiguationByReachability_268704_2() throws Exception {
|
||||||
waitForIndexer();
|
waitForIndexer();
|
||||||
|
|
||||||
String[] testData = getContentsForTest(4);
|
String[] testData = getContentsForTest(4);
|
||||||
|
|
Loading…
Add table
Reference in a new issue