PY-20769 Fixed: Support PEP 519: File system path protocol

Add __fspath__ to PY36_BUILTIN_METHODS
This commit is contained in:
Semyon Proshev
2016-11-15 15:39:04 +03:00
committed by Semyon Proshev
parent 13cc11735e
commit e67d313bf1
3 changed files with 13 additions and 0 deletions
@@ -1037,6 +1037,17 @@ public class PythonCompletionTest extends PyTestCase {
});
}
// PY-20769
public void testFsPathBuiltinMethod() {
runWithLanguageLevel(LanguageLevel.PYTHON36,
() -> {
doTestByText("class Cl(object):\n" +
" def __fspa<caret>");
myFixture.checkResult("class Cl(object):\n" +
" def __fspath__(self):");
});
}
@Override
protected String getTestDataPath() {
return super.getTestDataPath() + "/completion";