Skip to content

Commit b66268b

Browse files
author
Joachim Seminck
committed
Add failing test case
1 parent f0dcaca commit b66268b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tests/lib/rules/jsx-sort-props.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@ var expectedInvalidReservedFirstError = {
5656
var callbacksLastArgs = [{
5757
callbacksLast: true
5858
}];
59+
var ignoreCaseAndCallbackLastArgs = [{
60+
callbacksLast: true,
61+
ignoreCase: true
62+
}];
5963
var shorthandFirstArgs = [{
6064
shorthandFirst: true
6165
}];
@@ -109,6 +113,7 @@ ruleTester.run('jsx-sort-props', rule, {
109113
{code: '<App A b C />;', options: ignoreCaseArgs},
110114
// Sorting callbacks below all other props
111115
{code: '<App a z onBar onFoo />;', options: callbacksLastArgs},
116+
{code: '<App z onBar onFoo />;', options: ignoreCaseAndCallbackLastArgs},
112117
// Sorting shorthand props before others
113118
{code: '<App a b="b" />;', options: shorthandFirstArgs},
114119
{code: '<App z a="a" />;', options: shorthandFirstArgs},

0 commit comments

Comments
 (0)