Sha256: c2cf127162769c35a008479eb625bd5a0369284184906da0bc84a348f6af771a

Contents?: true

Size: 1.64 KB

Versions: 22

Compression:

Stored size: 1.64 KB

Contents

module('CSSImportRule');

test("@import url('button.css');", function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = "@import url('button.css');";
	equal(r.href, 'button.css');
	equal([].join.call(r.media, ', '), '');
});

test('@import url("button.css");', function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = '@import url("button.css");';
	equal(r.href, 'button.css');
	equal([].join.call(r.media, ', '), '');
});

test('@import url(button.css);', function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = '@import url(button.css);';
	equal(r.href, 'button.css');
	equal([].join.call(r.media, ', '), '');
});

test('@import "button.css";', function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = '@import "button.css";';
	equal(r.href, 'button.css');
	equal([].join.call(r.media, ', '), '');
});

test("@import 'button.css';", function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = "@import 'button.css';";
	equal(r.href, 'button.css');
	equal([].join.call(r.media, ', '), '');
});

test("@import url(size/medium.css) all;", function(){
	var r = new CSSOM.CSSImportRule;
	r.cssText = '@import url(size/medium.css) all;';
	equal(r.href, 'size/medium.css');
	equal([].join.call(r.media, ', '), "all");
	equal(r.media.mediaText, "all");
});

test('@import url(old.css) screen and (color), projection and (min-color: 256);', function() {
	var r = new CSSOM.CSSImportRule;
	r.cssText = '@import url(old.css) screen and (color), projection and (min-color: 256);';
	equal(r.href, 'old.css');
	equal([].join.call(r.media, ', '), 'screen and (color), projection and (min-color: 256)');
	equal(r.media.mediaText, 'screen and (color), projection and (min-color: 256)');
});

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
stylus-source-0.23.0 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.6 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.5 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.4 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.3 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.2 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.1 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.22.0 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.21.2 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.21.1 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.21.0 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.20.1 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.20.0 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.8 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.7 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.6 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.5 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.4 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.3 vendor/node_modules/cssom/test/CSSImportRule.test.js
stylus-source-0.19.2 vendor/node_modules/cssom/test/CSSImportRule.test.js