Skip to content

Commit 50ded4a

Browse files
committed
Small cleanup in engines tests
1 parent 64376a3 commit 50ded4a

File tree

1 file changed

+16
-22
lines changed

1 file changed

+16
-22
lines changed

test/engines_test.js

+16-22
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
/* global describe, it */
22

3-
43
'use strict';
54

6-
75
var assert = require('assert');
86

9-
107
describe('Engines', function () {
11-
128
var env = require('./environment')();
139

1410
describe('EJS', function () {
@@ -25,32 +21,16 @@ describe('Engines', function () {
2521
});
2622
});
2723

28-
describe('LESS', function () {
29-
it('should support context helpers', function () {
30-
var asset = env.findAsset('less_engine/stylesheet');
31-
assert(asset.toString().match(/\/assets\/ixti-[a-f0-9]{32}.gif/));
32-
assert(asset.toString().match(/data:image\/gif;base64/));
33-
});
34-
});
35-
36-
describe('SASS', function () {
37-
it('should process stylesheets', function () {
38-
var asset = env.findAsset('sass_engine/stylesheet');
39-
assert(asset.toString().match(/\.foo\s+\.bar\s*\{/));
40-
});
41-
});
42-
43-
4424
describe('JST', function () {
45-
describe('EJS', function () {
25+
describe('with EJS backend', function () {
4626
it('should compile to a JS function', function () {
4727
var asset = env.findAsset('jst_engine/ejs/template');
4828
assert(asset.toString().match(/this\.JST/));
4929
assert(asset.toString().match(/buf\.push/));
5030
});
5131
});
5232

53-
describe('JADE', function () {
33+
describe('with JADE backend', function () {
5434
it('should compile to a JS function', function () {
5535
var asset = env.findAsset('jst_engine/jade/template');
5636
assert(asset.toString().match(/this\.JST/));
@@ -61,4 +41,18 @@ describe('Engines', function () {
6141
});
6242
});
6343

44+
describe('LESS', function () {
45+
it('should support context helpers', function () {
46+
var asset = env.findAsset('less_engine/stylesheet');
47+
assert(asset.toString().match(/\/assets\/ixti-[a-f0-9]{32}.gif/));
48+
assert(asset.toString().match(/data:image\/gif;base64/));
49+
});
50+
});
51+
52+
describe('SASS', function () {
53+
it('should process stylesheets', function () {
54+
var asset = env.findAsset('sass_engine/stylesheet');
55+
assert(asset.toString().match(/\.foo\s+\.bar\s*\{/));
56+
});
57+
});
6458
});

0 commit comments

Comments
 (0)