Date: 18 October 2018
The Department of Internal Affairs Government Information Services group develops and maintains a suite of public and internal websites – SilverStripe-based sites deployed on the Common Web Platform.
The Department of Internal Affairs Government Information Services group develops and maintains a suite of public and internal websites – SilverStripe-based sites deployed on the Common Web Platform. This group is responsible for delivering government information through sites such as the Government services website, the data resources website, the New Zealand Gazette and the Government’s digital site.
What issue was DIA GIS experiencing?
Through the course of maintaining and developing these sites, substantial effort had been put into a variety of customised features above what the standard SilverStripe content management system provides. Custom features included the guided process that lead a citizen through the process of registering a new baby with the Government and a questionnaire to determine if you are a New Zealand citizen. The entirety of the Gazette front-end website and back-end management interfaces are comprised of particularly complex customisations to SilverStripe.
While some of these features had been provided with corresponding unit test cases, a large share of the feature set across the portfolio of sites had no automated testing. As a result, any changes to the website required significant effort in manual testing. The particularly error-prone process of actually upgrading the SilverStripe base CMS was so risky that it had been avoided for several months. As a result, the software base had grown out-of-date.
What did Assurity bring to the table?
Assurity brought deep experience in the space of Automated Testing, Continuous Integration and Specification By Example to help the GIS group transform how features were delivered and provide tooling to continuously test and report on the quality of the sites in the portfolio. Through targeted education with our Specification By Example course, team members were upskilled in how to write real-world, plain text test specifications early in the development process.
Specification By Example – Three Amigos
This process of shifting left helps developers move with greater velocity by guaranteeing quality before delivery downstream. Assurity also went through the existing feature customisation and developed automated test specifications to verify the functionality of those features across the four sites.
Assurity used the SilverStripe Behat extension to automate these plain-text test specifications. Behat basically translates plain text Gherkin test scenarios into executable Selenium scripts.
Assurity was responsible for developing over 50 automated test specifications across the portfolio, many of which can be reused for future sites. Finally Assurity aided in continuously testing the portfolio by onboarding the sites to the Continuous Integration tool CircleCI.
As each developer checks in code to the source repository, CircleCI will check it out and execute the entire suite of test specifications against the newly-updated code. Through CircleCI’s parallelisation features, more than 40 minutes of test scenarios could be executed within five minutes of the commit being checked in. Developers are notified of how their test performed against the scenarios within a few minutes. Any code that is to deployed to production must pass these test gates.
What effects did Assurity’s work have on GIS?
Assurity aided in not only developing test specifications for existing features, but also transforming how new features are developed moving forward. Through targeted upskilling in Specification By Example skills, Product Owners can now write test specifications as they write the user stories.
These test specifications can be translated into automated test specifications with little or no effort. As a result of this ‘shift-left’ investment, developers can move with greater velocity and confidence as they begin to implement new features or do things more fundamental like updating the SilverStripe installation.
What the client said…
“DIA GIS has taken another step forward with the implementation of a suite of automated tests (checks) across its portfolio. Thanks to the help of Allen Geer from Assurity, GIS can finally update its CWP sites to the latest version of CWP in a low-risk, low-cost fashion.
As part of our move towards DevOps, we are also training staff from across the department in Specification By Example (SBE). SBE is great for aligning understanding between business and developers as everyone contributes to writing SBE statements that outline how a new feature will work. Not only does SBE align people, it also nourishes collaboration and is easy to add to the growing library of automated tests”.