/*
 * Copyright (c) 2006 JetBrains s.r.o. All Rights Reserved.
 */
package com.intellij.psi.resolve;

import com.intellij.openapi.roots.LanguageLevelProjectExtension;
import com.intellij.pom.java.LanguageLevel;
import com.intellij.testFramework.ResolveTestCase;

/**
 * @author ven
 */
public abstract class Resolve15TestCase extends ResolveTestCase {
  private LanguageLevel myOldLanguageLevel;

  @Override
  protected void setUp() throws Exception {
    super.setUp();
    myOldLanguageLevel = LanguageLevelProjectExtension.getInstance(myJavaFacade.getProject()).getLanguageLevel();
    LanguageLevelProjectExtension.getInstance(myJavaFacade.getProject()).setLanguageLevel(LanguageLevel.JDK_1_5);
  }

  @Override
  protected void tearDown() throws Exception {
    LanguageLevelProjectExtension.getInstance(myJavaFacade.getProject()).setLanguageLevel(myOldLanguageLevel);
    super.tearDown();
  }
}

@@ -95,16 +95,199 @@
 solve;%0A%0A
+import com.intellij.openapi.projectRoots.JavaSdkVersion;%0Aimport com.intellij.openapi.projectRoots.JavaVersionService;%0Aimport com.intellij.openapi.projectRoots.JavaVersionServiceImpl;%0A
 import c
@@ -876,16 +876,144 @@
 K_1_5);%0A
+    ((JavaVersionServiceImpl)JavaVersionService.getInstance()).setTestVersion(JavaSdkVersion.JDK_1_5, getTestRootDisposable());%0A
   %7D%0A%0A  @

fix tests