File tree Expand file tree Collapse file tree 4 files changed +12
-5
lines changed Expand file tree Collapse file tree 4 files changed +12
-5
lines changed Original file line number Diff line number Diff line change 4040 "lint-staged" : " ^6.0.1" ,
4141 "memfs" : " ^2.6.0" ,
4242 "mocha-webpack" : " ^1.1.0" ,
43+ "rimraf" :" ^2.6.2" ,
4344 "ts-jest" : " ^22.4.2" ,
4445 "vue" : " ^2.5.16" ,
4546 "vue-property-decorator" : " ^6.0.0" ,
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ const create = require('@vue/cli-test-utils/createTestProject')
44const path = require ( 'path' )
55const cwd = path . resolve ( __dirname , '../../../test' )
66
7- async function createAndInstall ( name , options ) {
7+ async function createAndInstall ( name , options ) {
88 const project = await create (
99 name ,
1010 {
@@ -29,7 +29,7 @@ describe('invoke', () => {
2929 expect ( JSON . parse ( await project . read ( 'tsconfig.json' ) ) . include ) . toBeUndefined ( )
3030 } )
3131
32- xtest ( 'HelloWorld.vue should become HelloWorld/index.ts' , async ( ) => {
32+ test ( 'HelloWorld.vue should become HelloWorld/index.ts' , async ( ) => {
3333 const project = await createAndInstall ( `invoke-vuefile` , { } )
3434 expect ( project . has ( 'src/components/HelloWorld.vue' ) ) . toBe ( true )
3535 await project . run ( `${ require . resolve ( '@vue/cli/bin/vue' ) } invoke vue-cli-plugin-template-loader` )
Original file line number Diff line number Diff line change 11const extractParts = require ( '../lib/sfcSplitter' )
2+ const path = require ( 'path' )
3+ const rimraf = require ( 'rimraf' )
24
35module . exports = api => {
46 // transform .vue files into a folder with the same name containing
@@ -51,6 +53,9 @@ module.exports = api => {
5153 }
5254 }
5355 } )
54-
56+ const pathSource = path . resolve ( './src' )
57+ rimraf . sync ( pathSource )
58+ const testsSource = path . resolve ( './tests/unit' )
59+ rimraf . sync ( testsSource )
5560 api . render ( './template' )
5661}
Original file line number Diff line number Diff line change 11{
22 "name" : " vue-cli-plugin-template-loader" ,
3- "version" : " 0.5.1 " ,
3+ "version" : " 1.0.0 " ,
44 "description" : " vue-template-loader plugin for @vue/cli 3.0" ,
55 "main" : " index.js" ,
66 "repository" : {
2525 "access" : " public"
2626 },
2727 "dependencies" : {
28- "vue-template-loader" : " ^0.3.0"
28+ "vue-template-loader" : " ^0.3.0" ,
29+ "rimraf" : " ^2.6.2"
2930 }
3031}
You can’t perform that action at this time.
0 commit comments