mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PY-20752 PY-20754 PY-20798 Add tests
This commit is contained in:
@@ -0,0 +1 @@
|
||||
print(b'Hello %b!' <caret>% b'World')
|
||||
@@ -0,0 +1 @@
|
||||
print(b'Hello %b!' % b'World')
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
data = dict(first='Hodor', last='Hodor!')
|
||||
print('%(first)s %(last)s' <caret>% data)
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
data = dict(first='Hodor', last='Hodor!')
|
||||
print('{first} {last}'.format(**data))
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
data = {'first': 'Hodor', 'last': 'Hodor!'}
|
||||
print('%(first)s %(last)s' <caret>% data)
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
data = {'first': 'Hodor', 'last': 'Hodor!'}
|
||||
print('{first} {last}'.format(**data))
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
coord = (3, 5)
|
||||
print('X: %s; Y: %s' <caret>% coord)
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
coord = (3, 5)
|
||||
print('X: {}; Y: {}'.format(*coord))
|
||||
+20
@@ -43,4 +43,24 @@ public class PyConvertFormatOperatorToMethodIntentionTest extends PyIntentionTes
|
||||
public void testConcatenated() {
|
||||
doTest(PyBundle.message("INTN.replace.with.method"), LanguageLevel.PYTHON26);
|
||||
}
|
||||
|
||||
// PY-20752
|
||||
public void testTupleReference() {
|
||||
doTest(PyBundle.message("INTN.replace.with.method"), LanguageLevel.PYTHON26);
|
||||
}
|
||||
|
||||
// PY-20798
|
||||
public void testDictReference() {
|
||||
doTest(PyBundle.message("INTN.replace.with.method"), LanguageLevel.PYTHON26);
|
||||
}
|
||||
|
||||
// PY-20798
|
||||
public void testDictCallReference() {
|
||||
doTest(PyBundle.message("INTN.replace.with.method"), LanguageLevel.PYTHON26);
|
||||
}
|
||||
|
||||
// PY-20754
|
||||
public void testBytes() {
|
||||
doNegativeTest(PyBundle.message("INTN.replace.with.method"));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user