mirror of
http://gitea.com/actions/checkout
synced 2024-11-30 21:22:26 +08:00
updated unit tests
This commit is contained in:
parent
813c3f2d82
commit
041723abcc
@ -4,10 +4,9 @@ describe('isGhes tests', () => {
|
|||||||
it('basics', async () => {
|
it('basics', async () => {
|
||||||
expect(urlHelper.isGhes()).toBeFalsy()
|
expect(urlHelper.isGhes()).toBeFalsy()
|
||||||
expect(urlHelper.isGhes('https://github.com')).toBeFalsy()
|
expect(urlHelper.isGhes('https://github.com')).toBeFalsy()
|
||||||
//expect(urlHelper.isGhes('https://api.github.com')).toBeFalsy()
|
|
||||||
expect(urlHelper.isGhes('https://contoso.ghe.com')).toBeFalsy()
|
expect(urlHelper.isGhes('https://contoso.ghe.com')).toBeFalsy()
|
||||||
expect(urlHelper.isGhes('https://test.github.localhost')).toBeFalsy()
|
expect(urlHelper.isGhes('https://test.github.localhost')).toBeFalsy()
|
||||||
expect(urlHelper.isGhes('https://src.onpremise.customer.com')).toBeTruthy()
|
expect(urlHelper.isGhes('https://src.onpremise.fabrikam.com')).toBeTruthy()
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -27,7 +26,7 @@ describe('getServerApiUrl tests', () => {
|
|||||||
'https://api.fabrikam.ghe.com'
|
'https://api.fabrikam.ghe.com'
|
||||||
)
|
)
|
||||||
expect(
|
expect(
|
||||||
urlHelper.getServerApiUrl('https://src.onpremise.customer.com')
|
urlHelper.getServerApiUrl('https://src.onpremise.fabrikam.com')
|
||||||
).toBe('https://src.onpremise.customer.com/api/v3')
|
).toBe('https://src.onpremise.fabrikam.com/api/v3')
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user