Skip to content

Commit c08cac1

Browse files
committed
test: add scenario from issue #35
1 parent ca7bcd0 commit c08cac1

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/rule.spec.ts

+11
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,17 @@ describe('when classPropertiesAllowed is true', () => {
194194
});
195195
});
196196

197+
describe('issue #35', () => {
198+
ruleTester.run('prefer-arrow-functions', rule, {
199+
valid: [
200+
{
201+
code: 'export default async function fetchFoo() { return await fetch("/foo"); }',
202+
},
203+
],
204+
invalid: [],
205+
});
206+
});
207+
197208
describe('allowObjectProperties', () => {
198209
describe('when property can be converted to an arrow function', () => {
199210
describe('leaves the method as is when allowObjectProperties is true', () => {

0 commit comments

Comments
 (0)