forked from angular/angular-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathassets.ts
More file actions
16 lines (13 loc) · 730 Bytes
/
assets.ts
File metadata and controls
16 lines (13 loc) · 730 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import {writeFile, expectFileToExist, expectFileToMatch} from '../../utils/fs';
import {ng} from '../../utils/process';
import {expectToFail} from '../../utils/utils';
export default function() {
// TODO(architect): Delete this test. It is now in devkit/build-angular.
return writeFile('src/assets/.file', '')
.then(() => writeFile('src/assets/test.abc', 'hello world'))
.then(() => ng('build'))
.then(() => expectFileToExist('dist/test-project/favicon.ico'))
.then(() => expectFileToExist('dist/test-project/assets/.file'))
.then(() => expectFileToMatch('dist/test-project/assets/test.abc', 'hello world'))
.then(() => expectToFail(() => expectFileToExist('dist/test-project/assets/.gitkeep')));
}