Skip to content

Commit 186b6b0

Browse files
committed
[server] Temporarily disable broken bitbucket tests
1 parent b010d89 commit 186b6b0

File tree

5 files changed

+13
-17
lines changed

5 files changed

+13
-17
lines changed

components/server/src/bitbucket-server/bitbucket-server-api.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66

77
import { User } from "@gitpod/gitpod-protocol";
8-
import { ifEnvVarNotSet } from "@gitpod/gitpod-protocol/lib/util/skip-if";
98
import { Container, ContainerModule } from "inversify";
109
import { retries, skip, suite, test, timeout } from "@testdeck/mocha";
1110
import { expect } from "chai";
@@ -19,7 +18,7 @@ import { TokenProvider } from "../user/token-provider";
1918
import { BitbucketServerApi } from "./bitbucket-server-api";
2019
import { HostContextProvider } from "../auth/host-context-provider";
2120

22-
@suite(timeout(10000), retries(0), skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER")))
21+
@suite(timeout(10000), retries(0), skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER"))*/)
2322
class TestBitbucketServerApi {
2423
protected api: BitbucketServerApi;
2524
protected user: User;

components/server/src/bitbucket-server/bitbucket-server-context-parser.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66

77
import { User } from "@gitpod/gitpod-protocol";
8-
import { ifEnvVarNotSet } from "@gitpod/gitpod-protocol/lib/util/skip-if";
98
import { Container, ContainerModule } from "inversify";
109
import { skip, suite, test, timeout } from "@testdeck/mocha";
1110
import { expect } from "chai";
@@ -21,7 +20,7 @@ import { BitbucketServerApi } from "./bitbucket-server-api";
2120
import { HostContextProvider } from "../auth/host-context-provider";
2221
import { URL } from "url";
2322

24-
@suite(timeout(10000), skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER")))
23+
@suite(timeout(10000), skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER"))*/)
2524
class TestBitbucketServerContextParser {
2625
protected parser: BitbucketServerContextParser;
2726
protected user: User;

components/server/src/bitbucket-server/bitbucket-server-file-provider.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66

77
import { Repository, User } from "@gitpod/gitpod-protocol";
8-
import { ifEnvVarNotSet } from "@gitpod/gitpod-protocol/lib/util/skip-if";
98
import { Container, ContainerModule } from "inversify";
109
import { retries, skip, suite, test, timeout } from "@testdeck/mocha";
1110
import { expect } from "chai";
@@ -20,7 +19,7 @@ import { TokenProvider } from "../user/token-provider";
2019
import { BitbucketServerApi } from "./bitbucket-server-api";
2120
import { HostContextProvider } from "../auth/host-context-provider";
2221

23-
@suite(timeout(10000), retries(1), skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER")))
22+
@suite(timeout(10000), retries(1), skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER"))*/)
2423
class TestBitbucketServerFileProvider {
2524
protected service: BitbucketServerFileProvider;
2625
protected user: User;

components/server/src/bitbucket-server/bitbucket-server-repository-provider.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66

77
import { User } from "@gitpod/gitpod-protocol";
8-
import { ifEnvVarNotSet } from "@gitpod/gitpod-protocol/lib/util/skip-if";
98
import { Container, ContainerModule } from "inversify";
109
import { retries, skip, suite, test, timeout } from "@testdeck/mocha";
1110
import { expect } from "chai";
@@ -20,7 +19,7 @@ import { BitbucketServerApi } from "./bitbucket-server-api";
2019
import { HostContextProvider } from "../auth/host-context-provider";
2120
import { BitbucketServerRepositoryProvider } from "./bitbucket-server-repository-provider";
2221

23-
@suite(timeout(10000), retries(0), skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER")))
22+
@suite(timeout(10000), retries(0), skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER"))*/)
2423
class TestBitbucketServerRepositoryProvider {
2524
protected service: BitbucketServerRepositoryProvider;
2625
protected user: User;

components/server/src/bitbucket-server/bitbucket-server-token-validator.spec.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
* See License.AGPL.txt in the project root for license information.
55
*/
66

7-
import { ifEnvVarNotSet } from "@gitpod/gitpod-protocol/lib/util/skip-if";
87
import { Container, ContainerModule } from "inversify";
98
import { retries, skip, suite, test, timeout } from "@testdeck/mocha";
109
import { expect } from "chai";
@@ -15,12 +14,12 @@ import { BitbucketServerTokenHelper } from "./bitbucket-server-token-handler";
1514
import { TokenProvider } from "../user/token-provider";
1615
import { IGitTokenValidatorParams } from "../workspace/git-token-validator";
1716

18-
const shouldSkip =
19-
ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_READ") &&
20-
ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_WRITE") &&
21-
ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_ADMIN");
17+
// const shouldSkip =
18+
// ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_READ") &&
19+
// ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_WRITE") &&
20+
// ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_ADMIN");
2221

23-
@suite(timeout(10000), retries(0), skip(shouldSkip))
22+
@suite(timeout(10000), retries(0), skip(true) /*skip(shouldSkip)*/)
2423
class TestBitbucketServerTokenValidator {
2524
static readonly AUTH_HOST_CONFIG: Partial<AuthProviderParams> = {
2625
id: "MyBitbucketServer",
@@ -69,7 +68,8 @@ class TestBitbucketServerTokenValidator {
6968
return container.get(BitbucketServerTokenValidator);
7069
}
7170

72-
@test(skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_READ"))) async test_checkWriteAccess_read_only() {
71+
@test(skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_READ"))*/)
72+
async test_checkWriteAccess_read_only() {
7373
const token = process.env["GITPOD_TEST_TOKEN_BITBUCKET_SERVER_READ"]!;
7474
const result = await this.getValidator(token).checkWriteAccess(Object.assign({}, this.checkParams, { token }));
7575
expect(result).to.deep.equal({
@@ -79,7 +79,7 @@ class TestBitbucketServerTokenValidator {
7979
});
8080
}
8181

82-
@test(skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_WRITE")))
82+
@test(skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_WRITE"))*/)
8383
async test_checkWriteAccess_write_permissions() {
8484
const token = process.env["GITPOD_TEST_TOKEN_BITBUCKET_SERVER_WRITE"]!;
8585
const result = await this.getValidator(token).checkWriteAccess(Object.assign({}, this.checkParams, { token }));
@@ -90,7 +90,7 @@ class TestBitbucketServerTokenValidator {
9090
});
9191
}
9292

93-
@test(skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_ADMIN")))
93+
@test(skip(true) /*skip(ifEnvVarNotSet("GITPOD_TEST_TOKEN_BITBUCKET_SERVER_ADMIN"))*/)
9494
async test_checkWriteAccess_admin_permissions() {
9595
const token = process.env["GITPOD_TEST_TOKEN_BITBUCKET_SERVER_ADMIN"]!;
9696
const result = await this.getValidator(token).checkWriteAccess(Object.assign({}, this.checkParams, { token }));

0 commit comments

Comments
 (0)