void () { myFixture.addClass("package com.intellij.codeInspection; public class GlobalInspectionTool {} "); myFixture.testHighlighting("GlobalInspection.java", "plugin.xml"); IntentionAction intention = myFixture.findSingleIntention("Register inspection"); myFixture.launchAction(intention); myFixture.checkResultByFile("plugin.xml", "globalInspection.xml", true); }