GeoJSON
Spring
Hibernate
Liquid
Karma
Deploy
SASS
REST
Upgrade
Boot
Spring
Consume
Visualize
React
Angular

Are you afraid of snakes?

Python, Selenium

Have you ever wanted to create end to end tests for your app, but just can't find the time to get those tests working. Well, I have tried several frameworks from Cypress, to Selenium. I have always felt like this technology ought to be made simple. Just recently after taking another look at Selenium, I found the IDE to be very easy to use in order to quickly create scripts that could be improved by hand later. Here is a very simple example.

First I installed the Chrome Selenium extension.

https://docs.seleniumhq.org/selenium-ide/

I created a simple test using the record button and exported it as a Python test.

Then I installed the Python Webdriver using 

 
apt-get -y install python3.6
apt-get -y install python3-pip
pip3 selenium

Next I installed the chromedriver and I used NPM

 
npm install chromedriver

Now make sure you have Chrome installed. I used Headless on my server.

I may have added source first

 
apt-get -y install google-chrome-stable

Then I ran the following script with this command.

more...