update
This commit is contained in:
@@ -1,17 +1,29 @@
|
||||
// Disable TLS certificate validation for testing
|
||||
Deno.env.set('NODE_TLS_REJECT_UNAUTHORIZED', '0');
|
||||
Deno.env.set('SZCI_TEST', 'true');
|
||||
Deno.env.set('CI_REPOSITORY_URL', 'https://yyyyyy:xxxxxxxx@gitlab.com/mygroup/myrepo.git');
|
||||
|
||||
import { CloudlyConnector } from '../ts/connector.cloudly/cloudlyconnector.ts';
|
||||
import { Szci } from '../ts/szci.classes.szci.ts';
|
||||
|
||||
Deno.test('should be able to announce a container to cloudly', async () => {
|
||||
const cloudlyConnector = new CloudlyConnector(null);
|
||||
await cloudlyConnector.announceDockerContainer(
|
||||
{
|
||||
registryUrl: 'registry.losssless.com',
|
||||
tag: 'testcontainer',
|
||||
version: 'x.x.x',
|
||||
labels: [],
|
||||
},
|
||||
'cloudly.lossless.one'
|
||||
);
|
||||
Deno.test({
|
||||
name: 'should be able to announce a container to cloudly',
|
||||
sanitizeResources: false,
|
||||
sanitizeOps: false,
|
||||
fn: async () => {
|
||||
// Create a proper Szci instance for the connector
|
||||
const szciInstance = new Szci();
|
||||
await szciInstance.start();
|
||||
|
||||
const cloudlyConnector = new CloudlyConnector(szciInstance);
|
||||
await cloudlyConnector.announceDockerContainer(
|
||||
{
|
||||
registryUrl: 'registry.losssless.com',
|
||||
tag: 'testcontainer',
|
||||
version: 'x.x.x',
|
||||
labels: [],
|
||||
},
|
||||
'cloudly.lossless.one'
|
||||
);
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user