Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

tslint-jasmine-rules

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tslint-jasmine-rules - npm Package Compare versions

Comparing version 1.5.1 to 1.6.0

7

dist/callExpressionWalker.js

@@ -16,6 +16,7 @@ "use strict";

__extends(CallExpressionWalker, _super);
function CallExpressionWalker(sourceFile, options, regex, failureString) {
function CallExpressionWalker(sourceFile, options, regex, failureString, ruleSeverity) {
var _this = _super.call(this, sourceFile, options) || this;
_this.regex = regex;
_this.failureString = failureString;
_this.ruleSeverity = ruleSeverity;
return _this;

@@ -26,3 +27,5 @@ }

if (match) {
var fix = Lint.Replacement.deleteText(node.getStart(), 1);
var fix = this.ruleSeverity === "error"
? Lint.Replacement.deleteText(node.getStart(), 1)
: undefined;
this.addFailureAt(node.getStart(), match[0].length, this.failureString, fix);

@@ -29,0 +32,0 @@ }

module.exports = {
rulesDirectory: "./",
rulesDirectory: "./"
};

@@ -21,3 +21,3 @@ "use strict";

Rule.prototype.apply = function (sourceFile) {
return this.applyWithWalker(new callExpressionWalker_1.CallExpressionWalker(sourceFile, this.getOptions(), Rule.REGEX, Rule.FAILURE_STRING));
return this.applyWithWalker(new callExpressionWalker_1.CallExpressionWalker(sourceFile, this.getOptions(), Rule.REGEX, Rule.FAILURE_STRING, this.ruleSeverity));
};

@@ -24,0 +24,0 @@ Rule.FAILURE_STRING = "Disabled test (xit or xdescribe)";

@@ -21,3 +21,3 @@ "use strict";

Rule.prototype.apply = function (sourceFile) {
return this.applyWithWalker(new callExpressionWalker_1.CallExpressionWalker(sourceFile, this.getOptions(), Rule.REGEX, Rule.FAILURE_STRING));
return this.applyWithWalker(new callExpressionWalker_1.CallExpressionWalker(sourceFile, this.getOptions(), Rule.REGEX, Rule.FAILURE_STRING, this.ruleSeverity));
};

@@ -24,0 +24,0 @@ Rule.FAILURE_STRING = "Focused test (fit or fdescribe)";

{
"name": "tslint-jasmine-rules",
"version": "1.5.1",
"version": "1.6.0",
"description": "tslint rules for jasmine",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -35,1 +35,3 @@ # tslint-jasmine-rules

* no-disabled-tests
Fixes are __not__ applied when `"severity": "warning"` is used.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc