-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #688 from bugsnag/create_project_step
Create project via data access api and configure maze runner
- Loading branch information
Showing
4 changed files
with
59 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# @!group Setup steps | ||
|
||
# Creates a new project in bugsnag | ||
Given('I create a new project {string} with type {string}') do |name, type| | ||
org_id = data_access_api.get_first_org_id | ||
project = data_access_api.create_project(org_id, name, type) | ||
project_id = project['id'] | ||
data_access_api.set_project_id(project_id) | ||
api_key = data_access_api.get_project_api_key(project_id) | ||
Maze.config.bugsnag_repeater_api_key = api_key | ||
Maze.config.bugsnag_data_access_project_id = project_id | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
test/fixtures/pipeline-events/features/create_project_and_send_event.feature
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
Feature: We can create a project, send an event to the new project and verify | ||
that the event is available via the data access api | ||
|
||
Scenario: We can create a project, send an event to the new project and verify | ||
Given I create a new project "My Project" with type "ruby" | ||
When I send a request to the server | ||
Then I wait to receive an error | ||
And the last event is available via the data access api | ||
And the pipeline event payload field "exceptions.0.message" equals "This is an error" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters