mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Fixes a test-failure.
This commit is contained in:
parent
feffc835cb
commit
c80603bf86
4 changed files with 6 additions and 1 deletions
|
@ -49,6 +49,7 @@ import org.eclipse.cdt.core.index.IIndex;
|
|||
import org.eclipse.cdt.core.index.IIndexFile;
|
||||
import org.eclipse.cdt.core.index.IndexLocationFactory;
|
||||
import org.eclipse.cdt.core.model.CModelException;
|
||||
import org.eclipse.cdt.core.model.CoreModel;
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.core.testplugin.util.BaseTestCase;
|
||||
import org.eclipse.cdt.core.testplugin.util.TestSourceReader;
|
||||
|
@ -115,6 +116,8 @@ public class BaseUITestCase extends BaseTestCase {
|
|||
Thread.sleep(50);
|
||||
firstTime= false;
|
||||
|
||||
if (CCorePlugin.getIndexManager().isIndexerSetupPostponed(CoreModel.getDefault().create(file.getProject())))
|
||||
continue;
|
||||
index.acquireReadLock();
|
||||
try {
|
||||
IIndexFile pfile= index.getFile(ILinkage.CPP_LINKAGE_ID, IndexLocationFactory.getWorkspaceIFL(file));
|
||||
|
|
|
@ -46,6 +46,7 @@ public class CompletionTest_MacroRef_NoPrefix extends CompletionProposalsBaseTe
|
|||
"__null",
|
||||
"__real__",
|
||||
"__stdcall",
|
||||
"__thread",
|
||||
};
|
||||
|
||||
public CompletionTest_MacroRef_NoPrefix(String name) {
|
||||
|
|
|
@ -375,6 +375,7 @@ public class CompletionTests_PlainC extends AbstractContentAssistTest {
|
|||
"__null",
|
||||
"__real__",
|
||||
"__stdcall",
|
||||
"__thread",
|
||||
};
|
||||
assertCompletionResults(expected);
|
||||
}
|
||||
|
|
|
@ -917,7 +917,7 @@ public class CPPSelectionTestsNoIndexer extends BaseUITestCase {
|
|||
int offset = code.indexOf("rator short(); // F3"); //$NON-NLS-1$
|
||||
IASTNode decl = testF3(file, offset);
|
||||
assertTrue(decl instanceof IASTName);
|
||||
assertEquals(((IASTName)decl).toString(), "operator short"); //$NON-NLS-1$
|
||||
assertEquals(((IASTName)decl).toString(), "operator short int"); //$NON-NLS-1$
|
||||
assertEquals(((ASTNode)decl).getOffset(), 11);
|
||||
assertEquals(((ASTNode)decl).getLength(), 14);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue