Skip to content

Commit

Permalink
fix: ci
Browse files Browse the repository at this point in the history
  • Loading branch information
zaaack committed Nov 26, 2021
1 parent a8ce5f0 commit 7453632
Show file tree
Hide file tree
Showing 22 changed files with 16 additions and 52 deletions.
2 changes: 1 addition & 1 deletion src/test/fixtures/Foyfile1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { task, desc, option, logger } from '../../'
import { strict, setGlobalOptions } from '../../task'
import { resolve } from 'path'

setGlobalOptions({ strict: true, loading: false })
setGlobalOptions({ strict: true, loading: false, showTaskDuration: false })

desc('AA')
option('-a <val>', 'aa', { default: 12 })
Expand Down
2 changes: 1 addition & 1 deletion src/test/fixtures/Foyfile2.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { task, namespace, before, after, onerror, setGlobalOptions } from "../../task";
import { sleep } from '../../utils';
import { logger } from '../../logger';
setGlobalOptions({strict: true, loading: false})
setGlobalOptions({strict: true, loading: false, showTaskDuration: false})
before((t) => {
logger.log('beforeAll', t.name)
})
Expand Down
3 changes: 1 addition & 2 deletions src/test/fixtures/snaps/Foyfile1_ts_aa_-a_bb
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,4 @@ Task: aa
[debug] { '--': [], a: 'bb' }
[info] { '--': [], a: 'bb' }
[warn] { '--': [], a: 'bb' }
[error] { '--': [], a: 'bb' }
Task: aa done in 0s
[error] { '--': [], a: 'bb' }
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_async
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,5 @@ DependencyGraph for task [async]:
Task: wait
Task: wait
wait 1
Task: wait done in 0s
wait 100
Task: wait done in 0.1s
Task: async
Task: async done in 0.1s
Task: async
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_async_priority
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ DependencyGraph for task [async:priority]:

Task: wait
wait 100
Task: wait done in 0.1s
Task: wait
wait 1
Task: wait done in 0s
Task: async:priority
Task: async:priority done in 0.1s
Task: async:priority
4 changes: 1 addition & 3 deletions src/test/fixtures/snaps/Foyfile1_ts_bb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,5 @@ Task: aa
[info] {}
[warn] {}
[error] {}
Task: aa done in 0s
Task: bb
[debug] { '--': [] } { '--': [] }
Task: bb done in 0.01s
[debug] { '--': [] } { '--': [] }
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,8 @@ Task: aa
[info] {}
[warn] {}
[error] {}
Task: aa done in 0s
Task: bb
[debug] { test: 123 } { '--': [], c: 123 }
Task: bb done in 0.01s
Skip task: aa
Task: cc
[debug] { '--': [], c: 123 }
Task: cc done in 0.01s
[debug] { '--': [], c: 123 }
3 changes: 1 addition & 2 deletions src/test/fixtures/snaps/Foyfile1_ts_dd
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ DependencyGraph for task [dd]:
Task: dd
[info] $ pwd
[debug] p.stdout.trim() === ctx.cwd() true
[debug] true
Task: dd done in 0.11s
[debug] true
3 changes: 1 addition & 2 deletions src/test/fixtures/snaps/Foyfile1_ts_ee
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,4 @@ Task: ee
[info] $ echo aa
[info] $ echo bb
aa
bb
Task: ee done in 0.05s
bb
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_ff
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,9 @@ Task: aa
[info] { aa: 1 }
[warn] { aa: 1 }
[error] { aa: 1 }
Task: aa done in 0s
Task: aa
[debug] { aa: 2 }
[info] { aa: 2 }
[warn] { aa: 2 }
[error] { aa: 2 }
Task: aa done in 0s
Task: ff
Task: ff done in 0.01s
Task: ff
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_force
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,9 @@ Task: aa
[info] { noop: [Function: noop] }
[warn] { noop: [Function: noop] }
[error] { noop: [Function: noop] }
Task: aa done in 0s
Task: aa
[debug] { noop: [Function: noop] }
[info] { noop: [Function: noop] }
[warn] { noop: [Function: noop] }
[error] { noop: [Function: noop] }
Task: aa done in 0s
Task: force
Task: force done in 0s
Task: force
4 changes: 1 addition & 3 deletions src/test/fixtures/snaps/Foyfile1_ts_notForce
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,5 @@ Task: aa
[info] { noop: [Function: noop] }
[warn] { noop: [Function: noop] }
[error] { noop: [Function: noop] }
Task: aa done in 0s
Skip task: aa
Task: notForce
Task: notForce done in 0.01s
Task: notForce
3 changes: 1 addition & 2 deletions src/test/fixtures/snaps/Foyfile1_ts_pushpopd
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ Task: pushpopd
[info] pushd 2 works true
[info] cd works true
[info] popd works true
[info] popd 2 works true
Task: pushpopd done in 0.03s
[info] popd 2 works true
4 changes: 1 addition & 3 deletions src/test/fixtures/snaps/Foyfile1_ts_resolveOptions
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,5 @@ DependencyGraph for task [resolveOptions]:

Task: logOptions
[debug] logOptions { aa: 1, '--': [], c: 1, rawArgs: [] } { '--': [], c: 1 } []
Task: logOptions done in 0s
Task: resolveOptions
rawArgs []
Task: resolveOptions done in 0s
rawArgs []
4 changes: 1 addition & 3 deletions src/test/fixtures/snaps/Foyfile1_ts_resolveOptions_-c_123
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,5 @@ DependencyGraph for task [resolveOptions]:

Task: logOptions
[debug] logOptions { aa: 1, '--': [], c: 123, rawArgs: [ '-c', '123' ] } { '--': [], c: 123 } [ '-c', '123' ]
Task: logOptions done in 0s
Task: resolveOptions
rawArgs [ '-c', '123' ]
Task: resolveOptions done in 0s
rawArgs [ '-c', '123' ]
5 changes: 1 addition & 4 deletions src/test/fixtures/snaps/Foyfile1_ts_sync
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ DependencyGraph for task [sync]:

Task: wait
wait 100
Task: wait done in 0.1s
Task: wait
wait 1
Task: wait done in 0s
Task: sync
Task: sync done in 0.12s
Task: sync
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_error
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ DependencyGraph for task [error]:
[info] beforeAll error
Task: error
[info] error
Task: error done in 0s
[info] afterAll error
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_exec
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ Task: exec
[info] echo1 undefined
[info] $ sleep 1
[info] false function function
Task: exec done in 0.07s
[info] afterAll exec
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_ns1_error
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ DependencyGraph for task [ns1:error]:
[info] beforeAll ns1:error
[info] before ns1 ns1:error
Task: ns1:error
Task: ns1:error done in 0s
[error] Error: test error
at /home/z/Mine/foy/src/test/fixtures/Foyfile2.ts:45:11
at Generator.next (<anonymous>)
Expand Down
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_ns1_ns2_t2
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ DependencyGraph for task [ns1:ns2:t2]:
[info] before ns2 ns1:ns2:t2
Task: ns1:ns2:t2
[info] t2 ns ns1 ns2
Task: ns1:ns2:t2 done in 0s
[info] after ns2 ns1:ns2:t2
[info] after ns1 ns1:ns2:t2
[info] afterAll ns1:ns2:t2
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_ns1_t1
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,5 @@ DependencyGraph for task [ns1:t1]:
[info] before ns1 ns1:t1
Task: ns1:t1
[info] t1 ns ns1
Task: ns1:t1 done in 0s
[info] after ns1 ns1:t1
[info] afterAll ns1:t1
1 change: 0 additions & 1 deletion src/test/fixtures/snaps/Foyfile2_ts_start
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ DependencyGraph for task [start]:
[info] beforeAll start
Task: start
[info] start
Task: start done in 0s
[info] afterAll start

0 comments on commit 7453632

Please sign in to comment.