test: Added test event driver (#11222)
* Added test event driver * changed port to 28017 * updated credentials * updated password for postgres * Update forkedApp.json * fixing ImportExportForkApplication_spec * fixing ImportExportFork_spec * updating testdata Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
This commit is contained in:
parent
a877d137a6
commit
bd7ae1f924
|
|
@ -7,13 +7,13 @@
|
|||
"postgres-host": "localhost",
|
||||
"postgres-port": 5432,
|
||||
"postgres-databaseName": "fakeapi",
|
||||
"postgres-username": "postgres",
|
||||
"postgres-password": "postgres",
|
||||
"postgres-username": "docker",
|
||||
"postgres-password": "docker",
|
||||
"mysql-host": "localhost",
|
||||
"mysql-port": 3306,
|
||||
"mysql-databaseName": "fakeapi",
|
||||
"mysql-username": "root",
|
||||
"mysql-password": "root123",
|
||||
"mysql-password": "root",
|
||||
"mssql-host": "localhost",
|
||||
"mssql-port": 1433,
|
||||
"mssql-databaseName": "fakeapi",
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -35,7 +35,7 @@ describe("Import, Export and Fork application and validate data binding", functi
|
|||
// validating data binding for the imported application
|
||||
cy.xpath("//input[@value='Submit']").should("be.visible");
|
||||
cy.xpath("//div[text()='schema_name']").should("be.visible");
|
||||
cy.xpath("//div[text()='information_schema']").should("be.visible");
|
||||
cy.xpath("//div[text()='pg_toast']").should("be.visible");
|
||||
cy.xpath("//div[text()='title']").should("be.visible");
|
||||
cy.xpath("//div[text()='Recusan']").should("be.visible");
|
||||
});
|
||||
|
|
@ -62,7 +62,7 @@ describe("Import, Export and Fork application and validate data binding", functi
|
|||
// validating data binding for the forked application
|
||||
cy.xpath("//input[@value='Submit']").should("be.visible");
|
||||
cy.xpath("//div[text()='schema_name']").should("be.visible");
|
||||
cy.xpath("//div[text()='information_schema']").should("be.visible");
|
||||
cy.xpath("//div[text()='pg_toast']").should("be.visible");
|
||||
cy.xpath("//div[text()='title']").should("be.visible");
|
||||
cy.xpath("//div[text()='Recusan']").should("be.visible");
|
||||
});
|
||||
|
|
@ -116,9 +116,7 @@ describe("Import, Export and Fork application and validate data binding", functi
|
|||
// validating data binding for imported application
|
||||
cy.xpath("//input[@value='Submit']").should("be.visible");
|
||||
cy.xpath("//div[text()='schema_name']").should("be.visible");
|
||||
cy.xpath("//div[text()='information_schema']").should(
|
||||
"be.visible",
|
||||
);
|
||||
cy.xpath("//div[text()='pg_toast']").should("be.visible");
|
||||
cy.xpath("//div[text()='title']").should("be.visible");
|
||||
cy.xpath("//div[text()='Recusan']").should("be.visible");
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ echo "$APPSMITH_SSL_KEY" > ./docker/dev.appsmith.com-key.pem
|
|||
|
||||
echo "Going to run the nginx server"
|
||||
sudo docker pull nginx:latest
|
||||
sudo docker pull postgres:latest
|
||||
sudo docker pull appsmith/test-event-driver:latest
|
||||
|
||||
sudo docker run --network host --name wildcard-nginx -d -p 80:80 -p 443:443 \
|
||||
-v `pwd`/docker/nginx-root.conf:/etc/nginx/nginx.conf \
|
||||
|
|
@ -28,33 +28,15 @@ sudo docker run --network host --name wildcard-nginx -d -p 80:80 -p 443:443 \
|
|||
-v `pwd`/docker/dev.appsmith.com.pem:/etc/certificate/dev.appsmith.com.pem \
|
||||
-v `pwd`/docker/dev.appsmith.com-key.pem:/etc/certificate/dev.appsmith.com-key.pem \
|
||||
nginx:latest &
|
||||
sudo mkdir -p git-server/keys
|
||||
sudo mkdir -p git-server/repos
|
||||
|
||||
sudo docker run --network host --name postgres -d -p 5432:5432 \
|
||||
-e POSTGRES_PASSWORD=$POSTGRES_PASSWORD \
|
||||
-v `pwd`/cypress/init-pg-dump-for-test.sql:/docker-entrypoint-initdb.d/init-pg-dump-for-test.sql \
|
||||
--health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 \
|
||||
postgres:latest &
|
||||
sudo docker run --name test-event-driver -d -p 2222:22 -p 5001:5001 -p 3306:3306 \
|
||||
-p 5432:5432 -p 28017:27017 -v ~/git-server/keys:/git-server/keys \
|
||||
-v ~/git-server/repos:/git-server/repos appsmith/test-event-driver:latest
|
||||
|
||||
sudo docker run -p 127.0.0.1:3306:3306 --name mariadb -e MARIADB_ROOT_PASSWORD=root123 -d mariadb
|
||||
|
||||
echo "Sleeping for 30 seconds to let the MySQL start"
|
||||
sleep 30
|
||||
|
||||
sudo docker exec -i mariadb mysql -uroot -proot123 mysql < `pwd`/cypress/init-mysql-dump-for-test.sql
|
||||
|
||||
|
||||
echo "Sleeping for 30 seconds to let the servers start"
|
||||
sleep 30
|
||||
|
||||
sudo docker run -d -p 127.0.0.1:28017:27017 --name Cypress-mongodb -e MONGO_INITDB_DATABASE=appsmith -v `pwd`/cypress/mongodb:/data/db mongo
|
||||
echo "Sleeping for 30 seconds to let the servers start"
|
||||
sleep 30
|
||||
|
||||
sudo docker cp `pwd`/cypress/sample_airbnb Cypress-mongodb:/sample_airbnb
|
||||
|
||||
sudo docker exec -i Cypress-mongodb /usr/bin/mongorestore --db sample_airbnb /sample_airbnb/sample_airbnb
|
||||
|
||||
sleep 10
|
||||
echo "Waiting for test event driver to start"
|
||||
sleep 50
|
||||
|
||||
echo "Checking if the containers have started"
|
||||
sudo docker ps -a
|
||||
|
|
@ -90,4 +72,4 @@ fi
|
|||
|
||||
# DEBUG=cypress:* $(npm bin)/cypress version
|
||||
# sed -i -e "s|api_url:.*$|api_url: $CYPRESS_URL|g" /github/home/.cache/Cypress/4.1.0/Cypress/resources/app/packages/server/config/app.yml
|
||||
# cat /github/home/.cache/Cypress/4.1.0/Cypress/resources/app/packages/server/config/app.yml
|
||||
# cat /github/home/.cache/Cypress/4.1.0/Cypress/resources/app/packages/server/config/app.yml
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user