File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -5,12 +5,12 @@ Test sql query to your postgres database in cypres tests
55Use this plugin to query postgres database and use response in cypress tests
66
77# Installation
8-
8+ * Run below command in terminal to install the cypress postgres
99``` bash
1010npm i -D cypress-postgres
1111
1212```
13- then open your ` cypress/plugins/index.js ` file and register a new task
13+ * Open your ` cypress/plugins/index.js ` file and register a new task
1414```
1515module.exports = on => {
1616 on("task", {
@@ -22,14 +22,16 @@ module.exports = on => {
2222# How to use it
2323
2424To query postgres database follow below steps-
25-
26- * Add postgres database connection details in cypress.json file. Details are like-
27- "db":{"user": "postgres",
25+ * Add postgres database connection details in cypress.json file. Details like-
26+ ```
27+ "db":
28+ {"user": "postgres",
2829"host": "localhost",
2930"database": "postgres",
3031"password": "*****",
3132"port":5432
3233}
34+ ```
3335
3436* Use dbQuery task in your tests to query postgres database like below-
3537```
You can’t perform that action at this time.
0 commit comments