PY-14962 Add tests for new dict formatting options

This commit is contained in:
Mikhail Golubev
2015-05-14 13:37:24 +03:00
parent 33ab0e9b25
commit 3a2c670972
5 changed files with 40 additions and 0 deletions
@@ -0,0 +1,7 @@
{
"a": 1,
"bbb": [
2
],
"bbbbb": 3
}
@@ -0,0 +1,7 @@
{
"a" : 1,
"bbb" : [
2
],
"bbbbb": 3
}
@@ -0,0 +1,7 @@
{
"a": 1,
"bbb": [
2
],
"bbbbb": 3
}
@@ -0,0 +1,7 @@
{
"a": 1,
"bbb": [
2
],
"bbbbb": 3
}
@@ -567,6 +567,18 @@ public class PyFormatterTest extends PyTestCase {
doTest();
}
// PY-14962
public void testAlignDictLiteralOnValue() {
getCustomSettings().DICT_ALIGNMENT = PyCodeStyleSettings.DICT_ALIGNMENT_ON_VALUE;
doTest();
}
// PY-14962
public void testAlignDictLiteralOnColon() {
getCustomSettings().DICT_ALIGNMENT = PyCodeStyleSettings.DICT_ALIGNMENT_ON_COLON;
doTest();
}
// PY-15530
public void testAlignmentInArgumentListWhereFirstArgumentIsEmptyCall() {
doTest();