Files
github-slug-action/__tests__/shortsha.test.ts
Antoine Méausoone 13c2f38dad feat: add support for windows and macos jobs
BREAKING CHANGE: The action implementation move from container action to node.js action

Co-authored-by: Romain Lespinasse <romain.lespinasse@gmail.com>
2020-09-26 09:07:49 +02:00

11 lines
279 B
TypeScript

import {shortsha} from '../src/slug'
function test_short_sha(input: string, expected: string) {
let actual = shortsha(input)
expect(actual).toEqual(expected)
}
test('short_sha: long hash', () => {
test_short_sha('a35a1a486a260cfd99c5b6f8c6034a2929ba9b3f', 'a35a1a48')
})