Class LightJavaCodeInsightFixtureSpecTestCase

  • All Implemented Interfaces:
    com.intellij.testFramework.TestIndexingModeSupporter, com.vladsch.flexmark.test.util.SpecExampleProcessor, CodeInsightFixtureSpecTestCase, SpecTest, junit.framework.Test

    public abstract class LightJavaCodeInsightFixtureSpecTestCase
    extends com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
    implements CodeInsightFixtureSpecTestCase
    • Field Detail

      • myThrown

        public final org.junit.rules.ExpectedException myThrown
      • myExample

        @NotNull
        public @NotNull com.vladsch.flexmark.test.util.spec.SpecExample myExample
    • Constructor Detail

      • LightJavaCodeInsightFixtureSpecTestCase

        public LightJavaCodeInsightFixtureSpecTestCase​(@Nullable
                                                       @Nullable java.util.Map<java.lang.String,​? extends com.vladsch.flexmark.util.data.DataHolder> optionMap,
                                                       @Nullable
                                                       @Nullable com.vladsch.flexmark.util.data.DataHolder... defaultOptions)
    • Method Detail

      • before

        public void before()
                    throws java.lang.Throwable
        Throws:
        java.lang.Throwable
      • after

        public void after()
                   throws java.lang.Throwable
        Throws:
        java.lang.Throwable
      • options

        public final com.vladsch.flexmark.util.data.DataHolder options​(@NotNull
                                                                       @NotNull java.lang.String option)
        Specified by:
        options in interface com.vladsch.flexmark.test.util.SpecExampleProcessor
      • getProjectDescriptor

        @NotNull
        protected @NotNull com.intellij.testFramework.LightProjectDescriptor getProjectDescriptor()
        Overrides:
        getProjectDescriptor in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
      • test_case

        public final void test_case()
      • getFile

        public final com.intellij.psi.PsiFile getFile()
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Returns the file currently loaded into the in-memory editor.
        Specified by:
        getFile in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getFile in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Returns:
        the file currently loaded into the in-memory editor.
      • getEditor

        public final com.intellij.openapi.editor.ex.EditorEx getEditor()
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Returns the editor currently opened in the in-memory editor. to make it same as LightPlatformCodeInsightTestCase
        Specified by:
        getEditor in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getEditor in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Returns:
        editor currently opened in the in-memory editor.
      • getElementFactory

        public final com.intellij.psi.PsiElementFactory getElementFactory()
        Overrides:
        getElementFactory in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
      • getTempDirFixture

        @NotNull
        public final @NotNull com.intellij.testFramework.fixtures.TempDirTestFixture getTempDirFixture()
        Specified by:
        getTempDirFixture in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getTempDirFixture in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
      • getProject

        public final com.intellij.openapi.project.Project getProject()
        Specified by:
        getProject in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getProject in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
      • getPsiManager

        public final com.intellij.psi.PsiManager getPsiManager()
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Get PsiManager for the test
        Specified by:
        getPsiManager in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getPsiManager in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Returns:
        PsiManager
      • createLightFile

        public final com.intellij.psi.PsiFile createLightFile​(com.intellij.openapi.fileTypes.FileType fileType,
                                                              java.lang.String text)
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Create a light file for the given text
        Specified by:
        createLightFile in interface CodeInsightFixtureSpecTestCase
        Overrides:
        createLightFile in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Parameters:
        fileType - file type
        text - file text
        Returns:
        PsiFile
      • createLightFile

        public final com.intellij.psi.PsiFile createLightFile​(java.lang.String fileName,
                                                              com.intellij.lang.Language language,
                                                              java.lang.String text)
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Create a light file for the given text
        Specified by:
        createLightFile in interface CodeInsightFixtureSpecTestCase
        Overrides:
        createLightFile in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Parameters:
        fileName - file name
        language - language
        text - file text
        Returns:
        PsiFile
      • getModule

        @NotNull
        public final @NotNull com.intellij.openapi.module.Module getModule()
        Description copied from interface: CodeInsightFixtureSpecTestCase
        Get Module for the test
        Specified by:
        getModule in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getModule in class com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase
        Returns:
        Module
      • getTestRootDisposable

        @NotNull
        public final @NotNull com.intellij.openapi.Disposable getTestRootDisposable()
        Specified by:
        getTestRootDisposable in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getTestRootDisposable in class com.intellij.testFramework.UsefulTestCase
      • defaultRunBare

        public final void defaultRunBare​(@NotNull
                                         @NotNull com.intellij.util.ThrowableRunnable<java.lang.Throwable> testRunnable)
                                  throws java.lang.Throwable
        Specified by:
        defaultRunBare in interface CodeInsightFixtureSpecTestCase
        Overrides:
        defaultRunBare in class com.intellij.testFramework.UsefulTestCase
        Throws:
        java.lang.Throwable
      • disposeOnTearDown

        @NotNull
        public final <T extends com.intellij.openapi.Disposable> T disposeOnTearDown​(@NotNull
                                                                                     T disposable)
        Specified by:
        disposeOnTearDown in interface CodeInsightFixtureSpecTestCase
        Overrides:
        disposeOnTearDown in class com.intellij.testFramework.UsefulTestCase
      • getTestName

        @NotNull
        public final @NotNull java.lang.String getTestName​(boolean lowercaseFirstLetter)
        Specified by:
        getTestName in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getTestName in class com.intellij.testFramework.UsefulTestCase
      • getTestDirectoryName

        @NotNull
        public final @NotNull java.lang.String getTestDirectoryName()
        Specified by:
        getTestDirectoryName in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getTestDirectoryName in class com.intellij.testFramework.UsefulTestCase
      • assertNoThrowable

        public final void assertNoThrowable​(@NotNull
                                            @NotNull java.lang.Runnable closure)
        Specified by:
        assertNoThrowable in interface CodeInsightFixtureSpecTestCase
        Overrides:
        assertNoThrowable in class com.intellij.testFramework.UsefulTestCase
      • annotatedWith

        public final boolean annotatedWith​(@NotNull
                                           @NotNull java.lang.Class<? extends java.lang.annotation.Annotation> annotationClass)
        Specified by:
        annotatedWith in interface CodeInsightFixtureSpecTestCase
        Overrides:
        annotatedWith in class com.intellij.testFramework.UsefulTestCase
      • getHomePath

        @NotNull
        public final @NotNull java.lang.String getHomePath()
        Specified by:
        getHomePath in interface CodeInsightFixtureSpecTestCase
        Overrides:
        getHomePath in class com.intellij.testFramework.UsefulTestCase