@@ -1843,7 +1843,6 @@ describe('the dev middleware watcher', () => {
1843
1843
watchers . push ( watcher )
1844
1844
await isReady
1845
1845
expect ( middlewareExists ( ) ) . toBeTruthy ( )
1846
- console . log ( 'done should compile a middleware file and then exit when killed' )
1847
1846
} )
1848
1847
1849
1848
it . skip ( 'should compile a file if it is written after the watcher starts' , async ( ) => {
@@ -1857,7 +1856,6 @@ describe('the dev middleware watcher', () => {
1857
1856
await writeFile ( path . join ( process . cwd ( ) , 'middleware.ts' ) , middlewareSourceTs )
1858
1857
await isBuilt
1859
1858
expect ( middlewareExists ( ) ) . toBeTruthy ( )
1860
- console . log ( 'done should compile a file if it is written after the watcher starts' )
1861
1859
} )
1862
1860
1863
1861
it . skip ( 'should remove the output if the middleware is removed after the watcher starts' , async ( ) => {
@@ -1875,7 +1873,6 @@ describe('the dev middleware watcher', () => {
1875
1873
await unlink ( path . join ( process . cwd ( ) , 'middleware.ts' ) )
1876
1874
await isBuilt
1877
1875
expect ( middlewareExists ( ) ) . toBeFalsy ( )
1878
- console . log ( 'done should remove the output if the middleware is removed after the watcher starts' )
1879
1876
} )
1880
1877
1881
1878
it . skip ( 'should remove the output if invalid middleware is written after the watcher starts' , async ( ) => {
@@ -1893,7 +1890,6 @@ describe('the dev middleware watcher', () => {
1893
1890
await writeFile ( path . join ( process . cwd ( ) , 'middleware.ts' ) , 'this is not valid middleware' )
1894
1891
await isBuilt
1895
1892
expect ( middlewareExists ( ) ) . toBeFalsy ( )
1896
- console . log ( 'done should remove the output if invalid middleware is written after the watcher starts' )
1897
1893
} )
1898
1894
1899
1895
it . skip ( 'should recompile the middleware if it is moved into the src directory after the watcher starts' , async ( ) => {
@@ -1913,7 +1909,6 @@ describe('the dev middleware watcher', () => {
1913
1909
await move ( path . join ( process . cwd ( ) , 'middleware.ts' ) , path . join ( process . cwd ( ) , 'src' , 'middleware.ts' ) )
1914
1910
await isBuilt
1915
1911
expect ( middlewareExists ( ) ) . toBeTruthy ( )
1916
- console . log ( 'done should recompile the middleware if it is moved into the src directory after the watcher starts' )
1917
1912
} )
1918
1913
1919
1914
it . skip ( 'should recompile the middleware if it is moved into the root directory after the watcher starts' , async ( ) => {
@@ -1934,7 +1929,6 @@ describe('the dev middleware watcher', () => {
1934
1929
await move ( path . join ( process . cwd ( ) , 'src' , 'middleware.ts' ) , path . join ( process . cwd ( ) , 'middleware.ts' ) )
1935
1930
await isBuilt
1936
1931
expect ( middlewareExists ( ) ) . toBeTruthy ( )
1937
- console . log ( 'done should recompile the middleware if it is moved into the root directory after the watcher starts' )
1938
1932
} )
1939
1933
1940
1934
it . skip ( 'should compile the middleware if invalid source is replaced with valid source after the watcher starts' , async ( ) => {
@@ -1954,9 +1948,6 @@ describe('the dev middleware watcher', () => {
1954
1948
await writeFile ( path . join ( process . cwd ( ) , 'middleware.ts' ) , middlewareSourceTs )
1955
1949
await isBuilt
1956
1950
expect ( middlewareExists ( ) ) . toBeTruthy ( )
1957
- console . log (
1958
- 'done should compile the middleware if invalid source is replaced with valid source after the watcher starts' ,
1959
- )
1960
1951
} )
1961
1952
1962
1953
it ( 'should not compile middleware if more than one middleware file exists' , async ( ) => {
@@ -1971,7 +1962,6 @@ describe('the dev middleware watcher', () => {
1971
1962
await writeFile ( path . join ( process . cwd ( ) , 'middleware.js' ) , middlewareSourceJs )
1972
1963
await isBuilt
1973
1964
expect ( middlewareExists ( ) ) . toBeFalsy ( )
1974
- console . log ( 'done should not compile middleware if more than one middleware file exists' )
1975
1965
} )
1976
1966
1977
1967
it . skip ( 'should not compile middleware if a second middleware file is added after the watcher starts' , async ( ) => {
@@ -1989,7 +1979,6 @@ describe('the dev middleware watcher', () => {
1989
1979
await writeFile ( path . join ( process . cwd ( ) , 'middleware.js' ) , middlewareSourceJs )
1990
1980
await isBuilt
1991
1981
expect ( middlewareExists ( ) ) . toBeFalsy ( )
1992
- console . log ( 'done should not compile middleware if a second middleware file is added after the watcher starts' )
1993
1982
} )
1994
1983
1995
1984
it . skip ( 'should compile middleware if a second middleware file is removed after the watcher starts' , async ( ) => {
@@ -2010,7 +1999,6 @@ describe('the dev middleware watcher', () => {
2010
1999
await unlink ( path . join ( process . cwd ( ) , 'middleware.js' ) )
2011
2000
await isBuilt
2012
2001
expect ( middlewareExists ( ) ) . toBeTruthy ( )
2013
- console . log ( 'done should compile middleware if a second middleware file is removed after the watcher starts' )
2014
2002
} )
2015
2003
2016
2004
it . skip ( 'should generate the correct output for each case when middleware is compiled, added, removed and for error states' , async ( ) => {
0 commit comments