11import { PluginTester , testSpawn } from '@codifycli/plugin-test' ;
22import * as path from 'node:path' ;
3- import { describe , expect , it } from 'vitest'
3+ import * as fs from 'node:fs/promises' ;
4+ import * as os from 'node:os' ;
5+ import { afterAll , describe , expect , it } from 'vitest'
46
57describe ( 'Pip-sync resource integration tests' , ( ) => {
68 const pluginPath = path . resolve ( './src/index.ts' ) ;
79
810 it ( 'Installs python' , { timeout : 500_000 } , async ( ) => {
911 await PluginTester . fullTest ( pluginPath , [
1012 {
11- type : 'pyenv ' ,
13+ type : 'uv ' ,
1214 pythonVersions : [ '3.11' ] ,
13- global : '3.11'
15+ global : '3.11' ,
16+ tools : [ 'pip' ] ,
1417 } ,
1518 ] , {
1619 skipUninstall : true ,
@@ -25,7 +28,7 @@ describe('Pip-sync resource integration tests', () => {
2528 {
2629 'type' : 'git-repository' ,
2730 'directory' : '~/Projects/example-project2' ,
28- 'repository' : 'https://github.com/daniel-dqsdatalabs/python -template.git'
31+ 'repository' : 'https://github.com/ImperialCollegeLondon/pip-tools -template.git'
2932 } ,
3033 {
3134 'type' : 'venv-project' ,
@@ -49,4 +52,9 @@ describe('Pip-sync resource integration tests', () => {
4952 validateApply ( ) { } ,
5053 } ) ;
5154 } ) ;
55+
56+ afterAll ( async ( ) => {
57+ await fs . rm ( path . join ( os . homedir ( ) , 'Projects' , 'example-project2' ) , { recursive : true , force : true } ) ;
58+ await PluginTester . uninstall ( pluginPath , [ { type : 'uv' } ] ) ;
59+ } , 120_000 ) ;
5260} )
0 commit comments