Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
node-sass
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
楚学文
node-sass
Commits
e289389e
Commit
e289389e
authored
Sep 08, 2015
by
dotzero
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Test for --follow option
parent
aac339e6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
42 additions
and
0 deletions
+42
-0
cli.js
test/cli.js
+26
-0
index.scss
test/fixtures/follow/foo/bar/index.scss
+16
-0
No files found.
test/cli.js
View file @
e289389e
...
...
@@ -573,6 +573,32 @@ describe('cli', function() {
});
describe
(
'node-sass --follow --output output-dir input-dir'
,
function
()
{
it
(
'should compile with the --follow option'
,
function
(
done
)
{
var
src
=
fixture
(
'follow/input-dir'
);
var
dest
=
fixture
(
'follow/output-dir'
);
fs
.
mkdirSync
(
src
)
fs
.
symlinkSync
(
path
.
join
(
path
.
dirname
(
src
),
'foo'
),
path
.
join
(
src
,
'foo'
),
'dir'
)
var
bin
=
spawn
(
cli
,
[
src
,
'--follow'
,
'--output'
,
dest
]);
bin
.
once
(
'close'
,
function
()
{
var
expected
=
path
.
join
(
dest
,
'foo/bar/index.css'
);
fs
.
unlinkSync
(
path
.
join
(
path
.
dirname
(
src
),
'foo'
));
fs
.
rmdirSync
(
src
);
assert
(
fs
.
existsSync
(
expected
));
fs
.
unlinkSync
(
expected
);
expected
=
path
.
dirname
(
expected
);
fs
.
rmdirSync
(
expected
);
expected
=
path
.
dirname
(
expected
);
fs
.
rmdirSync
(
expected
);
fs
.
rmdirSync
(
dest
);
done
();
});
});
});
describe
(
'importer'
,
function
()
{
var
dest
=
fixture
(
'include-files/index.css'
);
var
src
=
fixture
(
'include-files/index.scss'
);
...
...
test/fixtures/follow/foo/bar/index.scss
0 → 100644
View file @
e289389e
#navbar
{
width
:
80%
;
height
:
23px
;
}
#navbar
ul
{
list-style-type
:
none
;
}
#navbar
li
{
float
:
left
;
a
{
font-weight
:
bold
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment