@@ -66,10 +66,7 @@ describe('searchUp nut test', () => {
6666 ) ;
6767 expect ( path . isAbsolute ( relativeStartPath ) ) . to . be . false ;
6868 const result = searchUp ( relativeStartPath , 'target.txt' ) ;
69- const expected = path . relative (
70- session . project . dir ,
71- path . join ( session . project . dir , 'level1' , 'level2' , 'target.txt' )
72- ) ;
69+ const expected = path . join ( session . project . dir , 'level1' , 'level2' , 'target.txt' ) ;
7370
7471 expect ( result ) . to . equal ( expected ) ;
7572 } ) ;
@@ -81,7 +78,7 @@ describe('searchUp nut test', () => {
8178 ) ;
8279 expect ( path . isAbsolute ( relativeStartPath ) ) . to . be . false ;
8380 const result = searchUp ( relativeStartPath , '.gitignore' ) ;
84- const expected = path . relative ( session . project . dir , path . join ( session . project . dir , '.gitignore' ) ) ;
81+ const expected = path . join ( session . project . dir , '.gitignore' ) ;
8582
8683 expect ( result ) . to . equal ( expected ) ;
8784 } ) ;
@@ -95,7 +92,7 @@ describe('searchUp nut test', () => {
9592 const absoluteStartPath = path . resolve ( session . project . dir , relativeStartPath ) ;
9693 fs . writeFileSync ( path . join ( absoluteStartPath , 'localFile.txt' ) , 'local content' ) ;
9794 const result = searchUp ( relativeStartPath , 'localFile.txt' ) ;
98- const expected = path . relative ( session . project . dir , path . join ( absoluteStartPath , 'localFile.txt' ) ) ;
95+ const expected = path . join ( absoluteStartPath , 'localFile.txt' ) ;
9996
10097 expect ( result ) . to . equal ( expected ) ;
10198 } ) ;
@@ -120,10 +117,7 @@ describe('searchUp nut test', () => {
120117 const absoluteFilePath = path . resolve ( session . project . dir , relativeFilePath ) ;
121118 fs . writeFileSync ( absoluteFilePath , 'content' ) ;
122119 const result = searchUp ( relativeFilePath , 'target.txt' ) ;
123- const expected = path . relative (
124- session . project . dir ,
125- path . join ( session . project . dir , 'level1' , 'level2' , 'target.txt' )
126- ) ;
120+ const expected = path . join ( session . project . dir , 'level1' , 'level2' , 'target.txt' ) ;
127121
128122 expect ( result ) . to . equal ( expected ) ;
129123 } ) ;
0 commit comments