-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: fixed broken tests and covered new functionalities (#56)
* fix: fixed broken tests and covered new functionalities * refactor: removed auth mock service * refactor: refactored undefined check in theme-import component
- Loading branch information
Showing
6 changed files
with
97 additions
and
134 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,21 @@ | ||
import { limitText } from './utils' | ||
import { filterObject, limitText } from './utils' | ||
|
||
describe('utils', () => { | ||
it('should limit text if text too long', () => { | ||
const result = limitText('textData', 4) | ||
expect(result).toBe('text...') | ||
}) | ||
|
||
it('should exclude props', () => { | ||
const obj = { | ||
name: 'John', | ||
surname: 'Doe', | ||
isVisible: true | ||
} | ||
const result = filterObject(obj, ['surname']) | ||
expect(result).toEqual({ | ||
name: 'John', | ||
isVisible: true | ||
}) | ||
}) | ||
}) |
This file was deleted.
Oops, something went wrong.
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
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