mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-20 02:08:47 +00:00
@@ -9,10 +9,10 @@ export = new class NoTestOnly implements eslint.Rule.RuleModule {
|
||||
|
||||
create(context: eslint.Rule.RuleContext): eslint.Rule.RuleListener {
|
||||
return {
|
||||
['MemberExpression[object.name="test"][property.name="only"]']: (node: any) => {
|
||||
['MemberExpression[object.name=/^(test|suite)$/][property.name="only"]']: (node: any) => {
|
||||
return context.report({
|
||||
node,
|
||||
message: 'test.only is a dev-time tool and CANNOT be pushed'
|
||||
message: 'only is a dev-time tool and CANNOT be pushed'
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user