@@ -46,9 +46,9 @@ describe("flags warnings with invalid scss", () => {
4646 ) )
4747 } )
4848
49- it ( "flags six warnings" , ( ) => {
49+ it ( "flags seven warnings" , ( ) => {
5050 return result . then ( data => (
51- expect ( data . results [ 0 ] . warnings . length ) . toBe ( 6 )
51+ expect ( data . results [ 0 ] . warnings . length ) . toBe ( 7 )
5252 ) )
5353 } )
5454
@@ -114,13 +114,13 @@ describe("flags warnings with invalid scss", () => {
114114
115115 it ( "correct third warning text" , ( ) => {
116116 return result . then ( data => (
117- expect ( data . results [ 0 ] . warnings [ 2 ] . text ) . toBe ( "Expected single space before \"{\" (block-opening-brace-space -before)" )
117+ expect ( data . results [ 0 ] . warnings [ 2 ] . text ) . toBe ( "Unexpected empty line before at-rule (at-rule-empty-line -before)" )
118118 ) )
119119 } )
120120
121121 it ( "correct third warning rule flagged" , ( ) => {
122122 return result . then ( data => (
123- expect ( data . results [ 0 ] . warnings [ 2 ] . rule ) . toBe ( "block-opening-brace-space -before" )
123+ expect ( data . results [ 0 ] . warnings [ 2 ] . rule ) . toBe ( "at-rule-empty-line -before" )
124124 ) )
125125 } )
126126
@@ -132,101 +132,131 @@ describe("flags warnings with invalid scss", () => {
132132
133133 it ( "correct third warning line number" , ( ) => {
134134 return result . then ( data => (
135- expect ( data . results [ 0 ] . warnings [ 2 ] . line ) . toBe ( 14 )
135+ expect ( data . results [ 0 ] . warnings [ 2 ] . line ) . toBe ( 22 )
136136 ) )
137137 } )
138138
139139 it ( "correct third warning column number" , ( ) => {
140140 return result . then ( data => (
141- expect ( data . results [ 0 ] . warnings [ 2 ] . column ) . toBe ( 5 )
141+ expect ( data . results [ 0 ] . warnings [ 2 ] . column ) . toBe ( 2 )
142142 ) )
143143 } )
144144
145145 it ( "correct forth warning text" , ( ) => {
146146 return result . then ( data => (
147- expect ( data . results [ 0 ] . warnings [ 3 ] . text ) . toBe ( "Unxpected empty line before @else (scss/ at-else -empty-line-before)" )
147+ expect ( data . results [ 0 ] . warnings [ 2 ] . text ) . toBe ( "Unexpected empty line before at-rule ( at-rule -empty-line-before)" )
148148 ) )
149149 } )
150150
151151 it ( "correct forth warning rule flagged" , ( ) => {
152152 return result . then ( data => (
153- expect ( data . results [ 0 ] . warnings [ 3 ] . rule ) . toBe ( "scss/ at-else -empty-line-before" )
153+ expect ( data . results [ 0 ] . warnings [ 2 ] . rule ) . toBe ( "at-rule -empty-line-before" )
154154 ) )
155155 } )
156156
157157 it ( "correct forth warning severity flagged" , ( ) => {
158158 return result . then ( data => (
159- expect ( data . results [ 0 ] . warnings [ 3 ] . severity ) . toBe ( "error" )
159+ expect ( data . results [ 0 ] . warnings [ 2 ] . severity ) . toBe ( "error" )
160160 ) )
161161 } )
162162
163163 it ( "correct forth warning line number" , ( ) => {
164164 return result . then ( data => (
165- expect ( data . results [ 0 ] . warnings [ 3 ] . line ) . toBe ( 14 )
165+ expect ( data . results [ 0 ] . warnings [ 2 ] . line ) . toBe ( 22 )
166166 ) )
167167 } )
168168
169169 it ( "correct forth warning column number" , ( ) => {
170170 return result . then ( data => (
171- expect ( data . results [ 0 ] . warnings [ 3 ] . column ) . toBe ( 1 )
171+ expect ( data . results [ 0 ] . warnings [ 2 ] . column ) . toBe ( 2 )
172172 ) )
173173 } )
174174
175175 it ( "correct fifth warning text" , ( ) => {
176176 return result . then ( data => (
177- expect ( data . results [ 0 ] . warnings [ 4 ] . text ) . toBe ( "Unexpected newline after \"} \" of @if statement (scss/at-if-closing- brace-newline-after )" )
177+ expect ( data . results [ 0 ] . warnings [ 3 ] . text ) . toBe ( "Expected single space before \"{ \" (block-opening- brace-space-before )" )
178178 ) )
179179 } )
180180
181181 it ( "correct fifth warning rule flagged" , ( ) => {
182182 return result . then ( data => (
183- expect ( data . results [ 0 ] . warnings [ 4 ] . rule ) . toBe ( "scss/at-if-closing- brace-newline-after " )
183+ expect ( data . results [ 0 ] . warnings [ 3 ] . rule ) . toBe ( "block-opening- brace-space-before " )
184184 ) )
185185 } )
186186
187187 it ( "correct fifth warning severity flagged" , ( ) => {
188188 return result . then ( data => (
189- expect ( data . results [ 0 ] . warnings [ 4 ] . severity ) . toBe ( "error" )
189+ expect ( data . results [ 0 ] . warnings [ 3 ] . severity ) . toBe ( "error" )
190190 ) )
191191 } )
192192
193193 it ( "correct fifth warning line number" , ( ) => {
194194 return result . then ( data => (
195- expect ( data . results [ 0 ] . warnings [ 4 ] . line ) . toBe ( 12 )
195+ expect ( data . results [ 0 ] . warnings [ 3 ] . line ) . toBe ( 14 )
196196 ) )
197197 } )
198198
199199 it ( "correct fifth warning column number" , ( ) => {
200200 return result . then ( data => (
201- expect ( data . results [ 0 ] . warnings [ 4 ] . column ) . toBe ( 2 )
201+ expect ( data . results [ 0 ] . warnings [ 3 ] . column ) . toBe ( 5 )
202202 ) )
203203 } )
204204
205205 it ( "correct sixth warning text" , ( ) => {
206206 return result . then ( data => (
207- expect ( data . results [ 0 ] . warnings [ 5 ] . text ) . toBe ( "Expected single space after \"}\" of @if statement (scss/at-if-closing-brace-space-after )" )
207+ expect ( data . results [ 0 ] . warnings [ 4 ] . text ) . toBe ( "Unxpected empty line before @else (scss/at-else-empty-line-before )" )
208208 ) )
209209 } )
210210
211211 it ( "correct sixth warning rule flagged" , ( ) => {
212212 return result . then ( data => (
213- expect ( data . results [ 0 ] . warnings [ 5 ] . rule ) . toBe ( "scss/at-if-closing-brace-space-after " )
213+ expect ( data . results [ 0 ] . warnings [ 4 ] . rule ) . toBe ( "scss/at-else-empty-line-before " )
214214 ) )
215215 } )
216216
217217 it ( "correct sixth warning severity flagged" , ( ) => {
218218 return result . then ( data => (
219- expect ( data . results [ 0 ] . warnings [ 5 ] . severity ) . toBe ( "error" )
219+ expect ( data . results [ 0 ] . warnings [ 4 ] . severity ) . toBe ( "error" )
220220 ) )
221221 } )
222222
223223 it ( "correct sixth warning line number" , ( ) => {
224224 return result . then ( data => (
225- expect ( data . results [ 0 ] . warnings [ 5 ] . line ) . toBe ( 12 )
225+ expect ( data . results [ 0 ] . warnings [ 4 ] . line ) . toBe ( 14 )
226226 ) )
227227 } )
228228
229229 it ( "correct sixth warning column number" , ( ) => {
230+ return result . then ( data => (
231+ expect ( data . results [ 0 ] . warnings [ 4 ] . column ) . toBe ( 1 )
232+ ) )
233+ } )
234+
235+ it ( "correct seventh warning text" , ( ) => {
236+ return result . then ( data => (
237+ expect ( data . results [ 0 ] . warnings [ 5 ] . text ) . toBe ( "Unexpected newline after \"}\" of @if statement (scss/at-if-closing-brace-newline-after)" )
238+ ) )
239+ } )
240+
241+ it ( "correct seventh warning rule flagged" , ( ) => {
242+ return result . then ( data => (
243+ expect ( data . results [ 0 ] . warnings [ 5 ] . rule ) . toBe ( "scss/at-if-closing-brace-newline-after" )
244+ ) )
245+ } )
246+
247+ it ( "correct seventh warning severity flagged" , ( ) => {
248+ return result . then ( data => (
249+ expect ( data . results [ 0 ] . warnings [ 5 ] . severity ) . toBe ( "error" )
250+ ) )
251+ } )
252+
253+ it ( "correct seventh warning line number" , ( ) => {
254+ return result . then ( data => (
255+ expect ( data . results [ 0 ] . warnings [ 5 ] . line ) . toBe ( 12 )
256+ ) )
257+ } )
258+
259+ it ( "correct seventh warning column number" , ( ) => {
230260 return result . then ( data => (
231261 expect ( data . results [ 0 ] . warnings [ 5 ] . column ) . toBe ( 2 )
232262 ) )
0 commit comments