-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: do not put space before title if there is no root suite
- Loading branch information
unlok
committed
Jan 27, 2022
1 parent
83249ff
commit f905879
Showing
2 changed files
with
24 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
'use strict'; | ||
|
||
const {mkFullTitle} = require('lib/gui/tool-runner/utils'); | ||
|
||
describe('lib/gui/tool-runner/utils', () => { | ||
describe('mkFullTitle', () => { | ||
it('should build title if array with path is not empty', () => { | ||
const suite = {path: ['p1', 'p2']}; | ||
const state = {name: 'state'}; | ||
|
||
assert.equal(mkFullTitle({suite, state}), 'p1 p2 state'); | ||
}); | ||
|
||
it('should build title if array with path is empty', () => { | ||
const suite = {path: []}; | ||
const state = {name: 'state'}; | ||
|
||
assert.equal(mkFullTitle({suite, state}), 'state'); | ||
}); | ||
}); | ||
}); |