/* Ċ Ġ* ĠCopyright Ġ 2 0 1 0 - 2 0 2 1 ĠJetBrains Ġs . r . o . Ġand ĠKotlin ĠProgramming ĠLanguage Ġcontributors . Ċ Ġ* ĠUse Ġof Ġthis Ġsource Ġcode Ġis Ġgoverned Ġby Ġthe ĠApache Ġ 2 . 0 Ġlicense Ġthat Ġcan Ġbe Ġfound Ġin Ġthe Ġlicense / LICENSE . txt Ġfile . Ċ Ġ*/ Ċ Ċ package Ġorg . jetbrains . kotlin . idea . quick fix Ċ Ċ import Ġcom . intellij . code Insight . int ention . Int ention Action Ċ import Ġcom . intellij . psi . Psi File Ċ import Ġorg . jetbrains . kotlin . psi . Kt File Ċ import Ġorg . jetbrains . kotlin . test . utils . Ignore Tests Ċ import Ġjava . nio . file . Files Ċ import Ġjava . nio . file . Path Ċ import Ġjava . nio . file . Paths Ċ Ċ abstract Ġclass ĠAbstract High Level Quick Fix Multi File Test Ġ: ĠAbstract Quick Fix Multi File Test () Ġ{ ĊĠĠĠ Ġoverride Ġfun Ġdo Test With Extra File ( before FileName : ĠString ) Ġ{ ĊĠĠĠĠĠĠĠ ĠIgnore Tests . run Test IfNot Disabled By File Directive ( ĊĠĠĠĠĠĠĠĠĠĠĠ ĠPaths . get ( before FileName ), ĊĠĠĠĠĠĠĠĠĠĠĠ Ġdisable Test Directive Ġ= ĠIgnore Tests . DIRECT IV ES . IGNORE _ FI R _ MULT IL INE _ COMMENT , ĊĠĠĠĠĠĠĠĠĠĠĠ Ġdirective Position Ġ= ĠIgnore Tests . Directive Position . LAST _ LINE _ IN _ FILE , ĊĠĠĠĠĠĠĠĠĠĠĠ Ġcompute Additional Files Ġ= Ġ{ Ġmain Test File Ġ-> ĠlistOf NotNull ( main Test File . get After File IfExists ()) Ġ}, ĊĠĠĠĠĠĠĠĠĠĠĠ Ġtest Ġ= Ġ{ Ġsuper . do Test With Extra File ( before FileName ) Ġ} ĊĠĠĠĠĠĠĠ Ġ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġval Ġcapture Exceptions : ĠBoolean Ġ= Ġfalse ĊĊĠĠĠ Ġoverride Ġfun Ġcheck For Unexpected Errors ( file : ĠK t File ) Ġ{} ĊĊĠĠĠ Ġoverride Ġfun Ġcheck Available Actions Are Expected ( file : ĠPsi File , Ġactions : ĠCollection < Int ention Action >) Ġ{} ĊĊĠĠĠ Ġprivate Ġfun ĠPath . get After File IfExists (): ĠPath ? Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġafter FileName Ġ= ĠfileName . toString (). remove Suffix (". before . Main . kt ") Ġ+ Ġ". after . kt " ĊĊĠĠĠĠĠĠĠ Ġreturn Ġresolve Sibling ( after FileName ). take If ( Files :: exists ) ĊĠĠĠ Ġ} Ċ }