-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Include SAP system details page e2e tests * Fix forgotten lines in the sap system overview feature file * Unify the Host link component usage * Comment out one test as it affects the rest of the suite * Remove not needed lines in sap system details feature file
- Loading branch information
Showing
11 changed files
with
321 additions
and
38 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
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
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,16 @@ | ||
import React from 'react'; | ||
|
||
import { Link } from 'react-router-dom'; | ||
|
||
const HostLink = ({ hostId, children }) => { | ||
return ( | ||
<span | ||
id={`host-${hostId}`} | ||
className="tn-hostname text-jungle-green-500 hover:opacity-75" | ||
> | ||
<Link to={`/hosts/${hostId}`}>{children}</Link> | ||
</span> | ||
); | ||
}; | ||
|
||
export default HostLink; |
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
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
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
45 changes: 45 additions & 0 deletions
45
test/e2e/cypress/fixtures/sap-system-details/sap_system_details.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,45 @@ | ||
Feature: SAP system details view | ||
This is where the user has a detailed view of the status of one specific discovered SAP system | ||
|
||
Background: | ||
Given a discovered SAP system within a SAP deployment with the following properties | ||
# Id: 'f534a4ad-cef7-5234-b196-e67082ffb50c', | ||
# Sid: 'NWD', | ||
# Hosts: ['vmnwdev01', 'vmnwdev02', 'vmnwdev03', 'vmnwdev04'] | ||
And 4 hosts associated to the SAP system | ||
|
||
Scenario: Detailed view of one specific SAP system is available | ||
When I navigate to a specific SAP system ('/sap_systems/f534a4ad-cef7-5234-b196-e67082ffb50c') | ||
Then the displayed SAP system SID is correct | ||
And the displayed SAP system has "Application server" type | ||
|
||
Scenario: Not found is given when the SAP system is not available | ||
When I navigate to a specific SAP system ('/sapsystems/other') | ||
Then Not found message is displayed | ||
|
||
Scenario: SAP system instances are properly shown | ||
Given I navigate to a specific SAP system ('/sap_systems/f534a4ad-cef7-5234-b196-e67082ffb50c') | ||
Then 4 instances are displayed | ||
And the data of each instance is correct | ||
And the status of each instance is GREEN | ||
|
||
Scenario: SAP system instances status change event is received | ||
Given I navigate to a specific SAP system ('/sap_systems/f534a4ad-cef7-5234-b196-e67082ffb50c') | ||
When a new SAP system event for this system with the 1st instance with a GRAY status is received | ||
Then the status of the 1st instance is GRAY | ||
When a new SAP system event for this system with the 1st instance with a GREEN status is received | ||
Then the status of the 1st instance is GREEN | ||
When a new SAP system event for this system with the 1st instance with a YELLOW status is received | ||
Then the status of the 1st instance is YELLOW | ||
When a new SAP system event for this system with the 1st instance with a RED status is received | ||
Then the status of the 1st instance is RED | ||
|
||
Scenario: New instance is discovered in the SAP system | ||
Given I navigate to a specific SAP system ('/sap_systems/f534a4ad-cef7-5234-b196-e67082ffb50c') | ||
When a new instance is discovered in a new agent | ||
Then the new instace is added in the layout table | ||
|
||
Scenario: The hosts table shows all associated hosts | ||
Given I navigate to a specific SAP system ('/sap_systems/f534a4ad-cef7-5234-b196-e67082ffb50c') | ||
Then the hosts table shows all the associated hosts | ||
And each host has correct data |
89 changes: 89 additions & 0 deletions
89
test/e2e/cypress/fixtures/sap-system-details/selected_system.js
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,89 @@ | ||
export const healthMap = { | ||
GREEN: 'bg-jungle-green-500', | ||
YELLOW: 'bg-yellow-500', | ||
RED: 'bg-red-500', | ||
GRAY: 'bg-gray-500', | ||
}; | ||
|
||
export const selectedSystem = { | ||
Id: 'f534a4ad-cef7-5234-b196-e67082ffb50c', | ||
Sid: 'NWD', | ||
Type: 'Application server', | ||
Hosts: [ | ||
{ | ||
Hostname: 'sapnwdas', | ||
Instance: '00', | ||
Features: 'MESSAGESERVER|ENQUE', | ||
HttpPort: '50013', | ||
HttpsPort: '50014', | ||
StartPriority: '1', | ||
Status: 'SAPControl-GREEN', | ||
StatusBadge: 'GREEN', | ||
}, | ||
{ | ||
Hostname: 'sapnwdpas', | ||
Instance: '01', | ||
Features: 'ABAP|GATEWAY|ICMAN|IGS', | ||
HttpPort: '50113', | ||
HttpsPort: '50114', | ||
StartPriority: '3', | ||
Status: 'SAPControl-GREEN', | ||
StatusBadge: 'GREEN', | ||
}, | ||
{ | ||
Hostname: 'sapnwdaas1', | ||
Instance: '02', | ||
Features: 'ABAP|GATEWAY|ICMAN|IGS', | ||
HttpPort: '50213', | ||
HttpsPort: '50214', | ||
StartPriority: '3', | ||
Status: 'SAPControl-GREEN', | ||
StatusBadge: 'GREEN', | ||
}, | ||
{ | ||
Hostname: 'sapnwder', | ||
Instance: '10', | ||
Features: 'ENQREP', | ||
HttpPort: '51013', | ||
HttpsPort: '51014', | ||
StartPriority: '0.5', | ||
Status: 'SAPControl-GREEN', | ||
StatusBadge: 'GREEN', | ||
}, | ||
], | ||
}; | ||
|
||
export const attachedHosts = [ | ||
{ | ||
Name: 'vmnwdev01', | ||
AgentId: '7269ee51-5007-5849-aaa7-7c4a98b0c9ce', | ||
Addresses: ['10.100.1.21', '10.100.1.25'], | ||
Provider: 'azure', | ||
Cluster: 'netweaver_cluster', | ||
Version: '0.7.1+git.dev42.1640084952.33229fc', | ||
}, | ||
{ | ||
Name: 'vmnwdev03', | ||
AgentId: '9a3ec76a-dd4f-5013-9cf0-5eb4cf89898f', | ||
Addresses: ['10.100.1.23', '10.100.1.27'], | ||
Provider: 'azure', | ||
Cluster: '', | ||
Version: '0.7.1+git.dev42.1640084952.33229fc', | ||
}, | ||
{ | ||
Name: 'vmnwdev04', | ||
AgentId: '1b0e9297-97dd-55d6-9874-8efde4d84c90', | ||
Addresses: ['10.100.1.24', '10.100.1.28'], | ||
Provider: 'azure', | ||
Cluster: '', | ||
Version: '0.7.1+git.dev42.1640084952.33229fc', | ||
}, | ||
{ | ||
Name: 'vmnwdev02', | ||
AgentId: 'fb2c6b8a-9915-5969-a6b7-8b5a42de1971', | ||
Addresses: ['10.100.1.22', '10.100.1.26'], | ||
Provider: 'azure', | ||
Cluster: 'netweaver_cluster', | ||
Version: '0.7.1+git.dev42.1640084952.33229fc', | ||
}, | ||
]; |
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
Oops, something went wrong.