sassy-test
Advanced tools
Comparing version 3.0.3 to 3.0.4
{ | ||
"name": "sassy-test", | ||
"version": "3.0.3", | ||
"version": "3.0.4", | ||
"homepage": "https://github.com/JohnAlbin/sassy-test", | ||
@@ -5,0 +5,0 @@ "author": "John Albin Wilkins <virtually.johnalbin@gmail.com> (http://john.albin.net/)", |
@@ -1,2 +0,2 @@ | ||
[![Build Status](https://secure.travis-ci.org/JohnAlbin/sassy-test.png?branch=master)](http://travis-ci.org/JohnAlbin/sassy-test) [![Coverage Status](https://coveralls.io/repos/JohnAlbin/sassy-test/badge.svg?branch=master&service=github)](https://coveralls.io/github/JohnAlbin/sassy-test?branch=master) | ||
[![Build Status](https://secure.travis-ci.org/JohnAlbin/sassy-test.png?branch=master)](http://travis-ci.org/JohnAlbin/sassy-test/builds) [![Coverage Status](https://coveralls.io/repos/JohnAlbin/sassy-test/badge.svg?branch=master&service=github)](https://coveralls.io/github/JohnAlbin/sassy-test?branch=master) | ||
@@ -85,3 +85,2 @@ | ||
expect(error).to.not.exist; | ||
expect(result.css).to.expect('.some-valid-css {border: 0}'); | ||
done(); | ||
@@ -128,5 +127,7 @@ }); | ||
it('should test an aspect of this function', function() { | ||
return sassyTest.renderFixture('my-modules-function', {}).then(function(result) { | ||
expect(result.css).to.expect('.some-valid-css {border: 0}'); | ||
}); | ||
// Sassy Test's renderFixture() will run a comparison test between the | ||
// rendered input.scss and the output.css. If we expect the comparison | ||
// test to succeed, we just need to return the Promise to mocha. But we | ||
// can run other tests in a `then()` if we desire. | ||
return sassyTest.renderFixture('my-modules-function', {}); | ||
}); | ||
@@ -136,4 +137,4 @@ | ||
return sassyTest.renderFixture('my-modules-error', {}).then(function(result) { | ||
// Make sure the test really does produce an error. | ||
expect(result).to.not.exist; | ||
// If the expected Sass error does not occur, we need to fail the test. | ||
throw new Error('An error should have occurred'); | ||
}).catch(function(error) { | ||
@@ -140,0 +141,0 @@ expect(error).to.exist; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
94731
163