Skip to content

Commit

Permalink
Update runner groups and contract tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jguz-pubnub committed Oct 21, 2024
1 parent d6592b7 commit c8f7659
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 36 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/commands-handler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
name: Process command
if: github.event.issue.pull_request && endsWith(github.repository, '-private') != true
runs-on:
group: Default
group: organization/Default
steps:
- name: Check referred user
id: user-check
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
name: Check release required
if: github.event.pull_request.merged && endsWith(github.repository, '-private') != true
runs-on:
group: Default
group: organization/Default
outputs:
release: ${{ steps.check.outputs.ready }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ jobs:
name: Tests
needs: [tests, acceptance-tests]
runs-on:
group: Default
group: organization/Default
steps:
- name: Tests summary
run: echo -e "\033[38;2;95;215;0m\033[1mAll tests successfully passed"
4 changes: 2 additions & 2 deletions .github/workflows/run-validations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
pubnub-yml:
name: "Validate .pubnub.yml"
runs-on:
group: Default
group: organization/Default
steps:
- name: Checkout project
uses: actions/checkout@v4
Expand Down Expand Up @@ -114,7 +114,7 @@ jobs:
name: Validations
needs: [pubnub-yml, package-managers-validation, demo-app-validation]
runs-on:
group: Default
group: organization/Default
steps:
- name: Validations summary
run: echo -e "\033[38;2;95;215;0m\033[1mAll validations passed"
48 changes: 20 additions & 28 deletions Tests/PubNubContractTest/PubNubContractCucumberTest.m
Original file line number Diff line number Diff line change
Expand Up @@ -49,34 +49,26 @@ void CucumberishInit(void) {

// TODO: REMOVE AFTER ALL TESTS FOR OBJECTS WILL BE MERGED.
NSArray *includedTags = @[
@"contract=getChannelMetadataOfChat",
@"contract=getChannelMetadataOfDMWithCustom",
@"contract=setChannelMetadataForChat",
@"contract=removeChannelMetadataOfChat",
@"contract=getAllChannelMetadata",
@"contract=getAllChannelMetadataWithCustom",

@"contract=getUUIDMetadataOfAlice",
@"contract=getUUIDMetadataOfBobWithCustom",
@"contract=setUUIDMetadataForAlice",
@"contract=removeUUIDMetadataOfAlice",
@"contract=getAllUUIDMetadata",
@"contract=getAllUUIDMetadataWithCustom",

@"contract=getMembersOfChatChannel",
@"contract=getMembersOfVipChatChannelWithCustomAndUuidWithCustom",
@"contract=setMembersForChatChannel",
@"contract=setMembersForChatChannelWithCustomAndUuidWithCustom",
@"contract=removeMembersForChatChannel",
@"contract=manageMembersForChatChannel",

@"contract=getAliceMemberships",
@"contract=getAliceMemberships",
@"contract=getBobMembershipWithCustomAndChannelCustom",
@"contract=setAliceMembership",
@"contract=removeAliceMembership",
@"contract=manageAliceMemberships"
];
@"contract=sendFileWithType",
@"contract=sendFileWithTooShortType",
@"contract=sendFileWithTooLongType",
@"contract=fetchHistoryWithPubNubMessageTypes",
@"contract=fetchHistoryWithUserAndPubNubTypes",
@"contract=fetchHistoryWithoutTypes",
@"contract=publishWithType",
@"contract=publishWithTooShortType",
@"contract=publishWithTooLongType",
@"contract=publishWithTypeStartingWithReservedStrings",
@"contract=publishWithTypeStartingWithNotAllowedCharacter",
@"contract=publishWithTypeContainingNotAllowedCharacter",
@"contract=signalWithType",
@"contract=signalWithTooShortType",
@"contract=signalWithTooLongType",
@"contract=signalWithTypeStartingWithReservedStrings",
@"contract=signalWithTypeStartingWithNotAllowedCharacter",
@"contract=signalWithTypeContainingNotAllowedCharacter",
@"contract=subscribeReceiveMessagesWithTypes"
];

NSBundle * bundle = [NSBundle bundleForClass:[PubNubContractTestCase class]];
[Cucumberish executeFeaturesInDirectory:@"Features"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public class PubNubFilesContractTestSteps: PubNubContractTestCase {
self.wait(for: [sendFileExpect], timeout: 60.0)
}

When("^I send a file with '(.+)' type$") { args, _ in
When("^I send a file with '(.+)' customMessageType$") { args, _ in
let type = args?.first ?? String()
let sendFileExpect = self.expectation(description: "Send file Response")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public class PubNubPublishContractTestSteps: PubNubContractTestCase {
self.wait(for: [publishMessageExpect], timeout: 60.0)
}

When("^I publish message with '(.*)' type$") { args, _ in
When("^I publish message with '(.*)' customMessageType$") { args, _ in
guard let type = args?.first as? String? else {
XCTAssertNotNil(args?.first, "Step match failed")
return
Expand Down Expand Up @@ -96,7 +96,7 @@ public class PubNubPublishContractTestSteps: PubNubContractTestCase {
}


When("^I send a signal with '(.*)' type$") { args, _ in
When("^I send a signal with '(.*)' customMessageType$") { args, _ in
guard let type = args?.last else {
XCTAssertNotNil(args?.first, "Step match failed")
return
Expand Down

0 comments on commit c8f7659

Please sign in to comment.