@@ -38,6 +38,10 @@ eslintTester.run('file-name', rule, {
38
38
// basic directive
39
39
filename : 'beautifulDirective.js' ,
40
40
code : 'app.directive("beautifulDirective", function() {});'
41
+ } , {
42
+ // basic component
43
+ filename : 'beautifulComponent.js' ,
44
+ code : 'app.component("beautifulComponent", {});'
41
45
} , {
42
46
// typeSeparator dot with filter
43
47
filename : 'src/app/myFilter.filter.js' ,
@@ -136,6 +140,33 @@ eslintTester.run('file-name', rule, {
136
140
ignoreTypeSuffix : true ,
137
141
ignorePrefix : 'xp'
138
142
} ]
143
+ } , {
144
+ // ignorePrefix xp with regex
145
+ filename : 'src/app/asset.service.js' ,
146
+ code : 'angular.factory("xp.AssetService", xpAssetService)' ,
147
+ options : [ {
148
+ typeSeparator : 'dot' ,
149
+ ignoreTypeSuffix : true ,
150
+ ignorePrefix : 'xp.'
151
+ } ]
152
+ } , {
153
+ // ignorePrefix xp in module name
154
+ filename : 'src/app/core.module.js' ,
155
+ code : 'angular.module("xp.core", function(){})' ,
156
+ options : [ {
157
+ typeSeparator : 'dot' ,
158
+ ignoreTypeSuffix : true ,
159
+ ignorePrefix : 'xp.'
160
+ } ]
161
+ } , {
162
+ // ignorePrefix xp in main module name
163
+ filename : 'src/app/xp.module.js' ,
164
+ code : 'angular.module("xp", function(){})' ,
165
+ options : [ {
166
+ typeSeparator : 'dot' ,
167
+ ignoreTypeSuffix : true ,
168
+ ignorePrefix : 'xp.'
169
+ } ]
139
170
} , {
140
171
// ignorePrefix st with typeSeparator dash
141
172
filename : 'src/app/appUtils-service.js' ,
@@ -224,6 +255,16 @@ eslintTester.run('file-name', rule, {
224
255
ignorePrefix : 'xp'
225
256
} ] ,
226
257
errors : [ { message : 'Filename must be "asset.service.js"' } ]
258
+ } , {
259
+ // ignorePrefix xp.
260
+ filename : 'src/app/xpAsset.service.js' ,
261
+ code : 'angular.factory("xp.AssetService", xpAssetService)' ,
262
+ options : [ {
263
+ typeSeparator : 'dot' ,
264
+ ignoreTypeSuffix : true ,
265
+ ignorePrefix : 'xp.'
266
+ } ] ,
267
+ errors : [ { message : 'Filename must be "asset.service.js"' } ]
227
268
} , {
228
269
// alphanumeric nameStyle dash and typeSeparator dash with service
229
270
filename : 'src/app/app2utils-service.js' ,
0 commit comments