DEV Community

Roman Rezinkin
Roman Rezinkin

Posted on

DPS909 - Lab 9


For this week in DPS909 our lab challenged us to implement continuous integration into our static site generators. To accomplish this, we would use Github Actions, which is going to allow us to automate workflows in response to events that occur in my static site generator Github Repo.


The setup part of GitHub Actions was rather simple, all we had to do was follow these steps. Since my project is developed in python, I ensured to use pytest as my testing platform, since my project already has test code written in pytest. Doing so would make it very easy to implement GitHub Actions into my repository.

The work

So now that GitHub Actions was configured, I had to make a new test in a branch. Luckily I forgot to implement a test for one of my functions, so after a quick implementation, I committed my changes and pushed them to my Repository.

Now after opening my PR, I was able to confirm that my continuous integration was operating as expected. So ensure that failures would be caught, I pushed a commit with a broken test, and on my PR I was able to see the failure.

The second part of the lab was to find a partner in our class, and test their continuous integration by implementing a new test case. I chose to work on A-Rokay's static site generator, as it was written in Python so it would be very easy to work on. Here is the Pull Request I made to test their continuous integration.


Overall, I really enjoyed implementing continuous integration into my repository. Introducing this will ensure that very high quality code is being pushed to the main branch. I think almost every repository should have some sort of testing enabled that provides some coverage of the code base.

Discussion (0)