fix(bucket-tenants): make tenant lifecycle and bucket import validation safer

This commit is contained in:
2026-05-02 12:09:13 +00:00
parent 7020810b5e
commit b075de1ecd
23 changed files with 435 additions and 183 deletions
+11
View File
@@ -75,6 +75,17 @@ tap.test('should expose disabled cluster health in standalone mode', async () =>
expect(clusterHealth.drives).toEqual(undefined);
});
tap.test('should expose health and metrics with auth disabled', async () => {
const health = await testSmartStorageInstance.getHealth();
expect(health.running).toEqual(true);
expect(health.auth.enabled).toEqual(false);
expect(health.auth.tenantCredentialCount).toEqual(0);
const metrics = await testSmartStorageInstance.getMetrics();
expect(metrics.tenantCredentialCount).toEqual(0);
expect(metrics.prometheusText).toMatch(/smartstorage_tenant_credentials_total 0/);
});
tap.test('should create a bucket', async () => {
const response = await s3Client.send(new CreateBucketCommand({ Bucket: 'test-bucket' }));
expect(response.$metadata.httpStatusCode).toEqual(200);