/*
 * User: anna
 * Date: 06-Mar-2008
 */
package com.jetbrains.python;

import com.intellij.codeInsight.completion.CodeCompletionHandlerBase;
import com.intellij.codeInsight.completion.CompletionType;
import com.intellij.testFramework.LightCodeInsightTestCase;

public class PythonCompletionTest extends LightCodeInsightTestCase{

  private void doTest() throws Exception {
    final String testName = getTestName(true);
    configureByFile(testName + ".py");
    new CodeCompletionHandlerBase(CompletionType.BASIC).invoke(getProject(), getEditor(), getFile());
    checkResultByFile(testName + ".after.py");
  }

  protected String getTestDataPath() {
    return PythonTestUtil.getTestDataPath() + "/completion/";
  }

  public void testLocalVar() throws Exception {
    doTest();
  }

  public void testSelfMethod() throws Exception {
    doTest();
  }

  public void testSelfField() throws Exception {
    doTest();
  }

  public void testFuncParams() throws Exception {
    doTest();
  }

  public void testFuncParamsStar() throws Exception {
    doTest();
  }

  public void testPredefinedMethodName() throws Exception {
    doTest();
  }

  public void testPredefinedMethodNot() throws Exception {
    doTest();
  }
}
/*
 * User: anna
 * Date: 06-Mar-2008
 */
package com.jetbrains.python;

import com.jetbrains.python.fixtures.PyLightFixtureTestCase;

public class PythonCompletionTest extends PyLightFixtureTestCase {

  private void doTest() throws Exception {
    final String testName = getTestName(true);
    myFixture.configureByFile(testName + ".py");
    myFixture.completeBasic();
    myFixture.checkResultByFile(testName + ".after.py");
  }

  protected String getTestDataPath() {
    return PythonTestUtil.getTestDataPath() + "/completion/";
  }

  public void testLocalVar() throws Exception {
    doTest();
  }

  public void testSelfMethod() throws Exception {
    doTest();
  }

  public void testSelfField() throws Exception {
    doTest();
  }

  public void testFuncParams() throws Exception {
    doTest();
  }

  public void testFuncParamsStar() throws Exception {
    doTest();
  }

  public void testPredefinedMethodName() throws Exception {
    doTest();
  }

  public void testPredefinedMethodNot() throws Exception {
    doTest();
  }
}
convert test to PyLightFixtureTestCase