Update testData for PyQuickDocTest.testOptionalParameterType so mock interpreter is not used anymore

This commit is contained in:
Semyon Proshev
2016-12-28 14:59:09 +03:00
parent 56f22b7f23
commit 75b3091a34
3 changed files with 4 additions and 16 deletions
@@ -1 +1 @@
<html><body><code>def <b>open</b>(file,&nbsp;mode='r',&nbsp;buffering=-1,&nbsp;encoding=None,&nbsp;errors=None,&nbsp;newline=None,&nbsp;closefd=True,&nbsp;opener=None)<br>Inferred&nbsp;type:&nbsp;(file:&nbsp;<a href="psi_element://#typename#str">str</a>,&nbsp;mode:&nbsp;<a href="psi_element://#typename#str">str</a>,&nbsp;buffering:&nbsp;Integral,&nbsp;encoding:&nbsp;Optional[<a href="psi_element://#typename#str">str</a>],&nbsp;errors:&nbsp;Optional[<a href="psi_element://#typename#str">str</a>],&nbsp;newline:&nbsp;Optional[<a href="psi_element://#typename#str">str</a>],&nbsp;closefd:&nbsp;<a href="psi_element://#typename#bool">bool</a>,&nbsp;opener:&nbsp;Optional[(<a href="psi_element://#typename#str">str</a>,&nbsp;<a href="psi_element://#typename#int">int</a>)&nbsp;-&gt;&nbsp;<a href="psi_element://#typename#int">int</a>])&nbsp;-&gt;&nbsp;Union[FileIO[<a href="psi_element://#typename#str">str</a>],&nbsp;TextIOWrapper[<a href="psi_element://#typename#unicode">unicode</a>]]<br><br></code>This is an alias for the builtin open() function.<br/><br/></body></html>
<html><body><code>def <b>open</b>(encoding:&nbsp;str&nbsp;=&nbsp;None,&nbsp;errors:&nbsp;str&nbsp;=&nbsp;None)<br>Inferred&nbsp;type:&nbsp;(encoding:&nbsp;Optional[<a href="psi_element://#typename#str">str</a>],&nbsp;errors:&nbsp;Optional[<a href="psi_element://#typename#str">str</a>])&nbsp;-&gt;&nbsp;None<br></code></body></html>
@@ -1,16 +1,4 @@
def open(file, mode='r', buffering=-1, encoding=None, errors=None, newline=None, closefd=True, opener=None):
"""This is an alias for the builtin open() function.
:type file: str
:type mode: str
:type buffering: numbers.Integral
:type encoding: str | None
:type errors: str | None
:type newline: str | None
:type closefd: bool
:type opener: ((str, int) -> int) | None
:rtype: io.FileIO[bytes] | io.TextIOWrapper[unicode]
"""
def open(encoding: str = None, errors: str = None):
pass
<the_ref>open("service")
<the_ref>open()
@@ -263,7 +263,7 @@ public class PyQuickDocTest extends LightMarkedTestCase {
// PY-17705
public void testOptionalParameterType() {
checkHTMLOnly();
runWithLanguageLevel(LanguageLevel.PYTHON35, this::checkHTMLOnly);
}
public void testHomogeneousTuple() {