Skip to content

Commit b4fe0fe

Browse files
committed
test(@angular-devkit/schematics): use HostTree instead of VirtualTree
1 parent c3ad789 commit b4fe0fe

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

packages/angular_devkit/schematics/src/rules/move_spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// tslint:disable:non-null-operator
99
import { of as observableOf } from 'rxjs';
1010
import { SchematicContext } from '../engine/interface';
11-
import { VirtualTree } from '../tree/virtual';
11+
import { HostTree } from '../tree/host-tree';
1212
import { callRule } from './call';
1313
import { move } from './move';
1414

@@ -18,7 +18,7 @@ const context: SchematicContext = null !;
1818

1919
describe('move', () => {
2020
it('works on moving the whole structure', done => {
21-
const tree = new VirtualTree();
21+
const tree = new HostTree();
2222
tree.create('a/b/file1', 'hello world');
2323
tree.create('a/b/file2', 'hello world');
2424
tree.create('a/c/file3', 'hello world');
@@ -34,7 +34,7 @@ describe('move', () => {
3434
});
3535

3636
it('works on moving a subdirectory structure', done => {
37-
const tree = new VirtualTree();
37+
const tree = new HostTree();
3838
tree.create('a/b/file1', 'hello world');
3939
tree.create('a/b/file2', 'hello world');
4040
tree.create('a/c/file3', 'hello world');

packages/angular_devkit/schematics/src/rules/random.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* found in the LICENSE file at https://angular.io/license
77
*/
88
import { Source } from '../engine/interface';
9-
import { VirtualTree } from '../tree/virtual';
9+
import { HostTree } from '../tree/host-tree';
1010

1111

1212
function generateStringOfLength(l: number) {
@@ -32,7 +32,7 @@ export default function(options: RandomOptions): Source {
3232
return () => {
3333
const root = ('root' in options) ? options.root : '/';
3434

35-
const map = new VirtualTree();
35+
const map = new HostTree();
3636
const nbFiles = ('multiFiles' in options)
3737
? (typeof options.multiFiles == 'number' ? options.multiFiles : random(2, 12))
3838
: 1;

0 commit comments

Comments
 (0)