mirror of
https://github.com/actions/setup-java.git
synced 2025-04-21 10:26:46 +00:00
Implement getAvailableVersions
This commit is contained in:
parent
dd80852400
commit
852fac3790
3 changed files with 129 additions and 0 deletions
23
__tests__/distributors/coretto-installer.test.ts
Normal file
23
__tests__/distributors/coretto-installer.test.ts
Normal file
|
@ -0,0 +1,23 @@
|
|||
import { HttpClient } from '@actions/http-client';
|
||||
|
||||
import { CorettoDistribution } from '../../src/distributions/coretto/installer';
|
||||
import { JavaInstallerOptions } from '../../src/distributions/base-models';
|
||||
|
||||
describe('getAvailableVersions', () => {
|
||||
beforeEach(() => {});
|
||||
|
||||
afterEach(() => {});
|
||||
|
||||
it('load available versions', async () => {
|
||||
const distribution = new CorettoDistribution('coretto', {
|
||||
version: '11',
|
||||
architecture: 'x64',
|
||||
packageType: 'jdk',
|
||||
checkLatest: false
|
||||
});
|
||||
|
||||
const availableVersions = await distribution['getAvailableVersions']();
|
||||
expect(availableVersions).not.toBeNull();
|
||||
expect(availableVersions.length).toBe(24);
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue