Package org.eclipse.jdt.ui.text.java

Examples of org.eclipse.jdt.ui.text.java.ContentAssistInvocationContext


    String prefix = "";
    String postfix = "";

    int position = testFileText.indexOf(label) + characterOffset - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    int countOfClasspathFiles = getListOfPossibleClasspathConfigFiles().size();
    String errorMessage = "Wrong number of proposals: expecting " + getListOfPossibleClasspathConfigFiles().size()
        + " and got " + proposals.size();
    assertTrue(errorMessage, proposals.size() == getListOfPossibleClasspathConfigFiles().size());
View Full Code Here


    String label = "testValueCompletion";

    int position = testFileText.indexOf(label) + newlineLength + label.length()
        + "\t@ContextConfiguration(value = { \"subdir".length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    assertTrue(proposals.size() == 1);

    String expectedString = "classpath:subdir/content-configuration-assist-test.xml";
View Full Code Here

    String prefix = "";
    String postfix = "";

    int position = testFileText.indexOf(label) + newlineLength + label.length() + annotationLineStart.length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);

    ArrayList<String> expectedProposals = createAffixedProposals(prefix, postfix,
        getListOfPossibleNonClasspathConfigFiles());
View Full Code Here

    String label = "testNonClasspathTypeFullPath";
    String annotationLineStart = "\t@ContextConfiguration(value = { \"non-classpath/arb";

    int position = testFileText.indexOf(label) + newlineLength + label.length() + annotationLineStart.length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    String errorMessage = "Expecting 1 proposal, but got " + proposals.size();
    assertTrue(errorMessage, proposals.size() == 1);

    String expectedString = "file:non-classpath/arbitrary.xml";
View Full Code Here

    String label = "testNonClasspathTypeBasename";
    String annotationLineStart = "\t@ContextConfiguration(value = { \"arbitrary";

    int position = testFileText.indexOf(label) + newlineLength + label.length() + annotationLineStart.length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    String errorMessage = "Expecting 1 proposal, but got " + proposals.size();
    assertTrue(errorMessage, proposals.size() == 1);

    String expectedString = "file:non-classpath/arbitrary.xml";
View Full Code Here

    String label = "testFileColon";
    String annotationLineStart = "\t@ContextConfiguration(value = { \"file:";

    int position = testFileText.indexOf(label) + newlineLength + label.length() + annotationLineStart.length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    String errorMessage = "Expecting " + getListOfPossibleNonClasspathConfigFiles().size() + " proposals, but got "
        + proposals.size();
    assertTrue(errorMessage, proposals.size() == getListOfPossibleNonClasspathConfigFiles().size());
View Full Code Here

    String label = "testClasspathColon";
    String annotationLineStart = "\t@ContextConfiguration(value = { \"classpath:";

    int position = testFileText.indexOf(label) + newlineLength + label.length() + annotationLineStart.length() - 1;

    ContentAssistInvocationContext context = createTestContext(position);
    List<ICompletionProposal> proposals = computer.computeCompletionProposals(context, null);
    String errorMessage = "Expecting " + getListOfPossibleClasspathConfigFiles().size() + " proposals, but got "
        + proposals.size();
    assertTrue(errorMessage, proposals.size() == getListOfPossibleClasspathConfigFiles().size());
View Full Code Here

TOP

Related Classes of org.eclipse.jdt.ui.text.java.ContentAssistInvocationContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.