Cycle includes the ability to save Connections and Credentials for your systems under test. Using named Connections and Credentials streamlines and simplifies declaring system access, makes Features look cleaner and promotes reusability of “set it and forget it” parameters.
Connections are the strings, IPs, URLs used to access specific systems/machines under test. Connections are stored in the .cycproj file as they tend to be global for the project. This allows the file to be stored in a repository or shared among all project team members. It is strongly recommended to commit this file to your repository or at least create a back up in the event any files become corrupted and to avoid having to reenter all of your saved connections.
Credentials are the logins and passwords for the Connections. Credentials are stored in the .cycuser file so that they are more securely stored at the local level for the specific user. It is strongly recommended to create a local back up in the event any files become corrupted and to avoid having to reenter all of your saved credentials. We do not recommend this file be stored in a repository due to user specific logins.
Connections and Credentials work in concert either through direct step access or through Scenario Outline declaration.
Then I connect to MOCA "<CONNECTION>" logged in as "<CREDENTIALS>"
Then I connect to database "<CONNECTION>" logged in as "<CREDENTIALS>"
Scenario Outline: SQL Test
SQL Examples:scripts\wh.sql connected to <DATABASE_CONNECTION> logged in as <DATABASE_CREDENTIALS>
NOTE: When using direct database connections that may require a specific database name, such as DB2, Oracle, SQLServer, MySQL, H2, it is recommended to add the database name directly into the Connection.
Using SQLServer as an example the database specific connection string would be: HOST:PORT;DatabaseName=DATABASE