| 35 | } |
| 36 | |
| 37 | override visitIdentifier(node: ts.Identifier): void { |
| 38 | if (!this._enabled) { |
| 39 | return; |
| 40 | } |
| 41 | |
| 42 | const symbol = this._typeChecker.getSymbolAtLocation(node); |
| 43 | const decl = symbol?.valueDeclaration; |
| 44 | if (decl && ts.isVariableDeclaration(decl) && decl.name.getText() === 'Zone') { |
| 45 | this.addFailureAtNode(node, `Using Zone is not allowed.`); |
| 46 | } |
| 47 | } |
| 48 | |
| 49 | override visitPropertyAccessExpression(node: ts.PropertyAccessExpression) { |
| 50 | if (!this._enabled || this._sourceFile.fileName.endsWith('.spec.ts')) { |