Using chatbots to automate testing

Using chatbots to automate testing

I guess most development teams use IM / chatrooms for general communication amongst the team. At Infraxis we do that too - we have a distributed team across the globe who work together on shared infrastructure to build, deploy and test our products.

There's often a point where there'll be a request in the chatroom like "can someone redeploy the QA environment" and then one of the team members will kick off a build in Jenkins, which runs an automated regression test too. That's ok - but if we automate it even further, then any member of the team can deploy and test rather than just those who have the relevant know-how - without learning anything about the deployment system or the testing harness. And if we could do it right there in the chatroom, we'd have full visibility of the outcome in the place we're already focusing on for communication. Hmmmm...

Hubot 

Hubot is a scripted bot library, which can be integrated into all kinds of popular chat apps, and can automate almost anything.

Using Hubot, I built a  wrapper for the API of our in-house collaborative Payments testing product "IQS" - just as a proof of concept to see if I could do it. Once you get used to coffee script it's quite straightforward - this uses just 18 lines of code.

IQS provides a RESTful test execution API, requiring two parameters - an access token, and a test scenario name - a short name for the test scenario to be run.

The Hubot script responds to the request "run iqs test [test scenario nickname]" . I deployed Hubot to Heroku, integrated the bot - which I called 'ixbot' - into Slack, pointed it at our IQS QA system and gave it a try :

I asked it to run the test scenario called "bot demo" for this test.

ixbot understood the command and kicked off the API call to IQS, responding immediately on receipt of the request, and getting back to me shortly afterwards with the outcome of the tests.

We'll continue expanding on this to completely integrate automated deployment and testing into our developer chatroom. Then it becomes extra easy to run automated tasks, regardless of the individual's skills.

Igor Kim

CEO & Co-Founder | Owner Ptolemay | Life is too short to build shitty things

1 年

Dan, thanks for sharing!

回复
Dan Graf

Automating Carbon Accounting

9 年

ChatOps - like it Amancio, hadn't heard it given a name befire - I had a read about that term just now and found a good primer article : https://blogs.atlassian.com/2016/01/what-is-chatops-adoption-guide/

回复
Dr. Amancio Bouza

API & AI Enthusiast ★ Digital Products & Ecosystems ★ Dot Connector ★ Author of API Product Management & Speaker

9 年

Thanks a lot for this article regarding ChatOps. Currently, some colleagues and me are working on a prototype in the context of continuous delivery.

要查看或添加评论,请登录

Dan Graf的更多文章

  • Four ways we use AI to accelerate carbon reporting

    Four ways we use AI to accelerate carbon reporting

    AI can fundamentally transform the way data is gathered for carbon accounting by simultaneously addressing several…

    2 条评论
  • Is Scope 3 Too Big To Swallow ?

    Is Scope 3 Too Big To Swallow ?

    Where is the "orchestration layer" to integrate the various standards, specialised platforms, tools and surveys for…

    11 条评论
  • Black Boxes

    Black Boxes

    Can we abstract complex science into a "black box" to emphasise actionable insights over the minutiae of debate ? This…

    2 条评论
  • Green Slopes

    Green Slopes

    Reflecting on the pristine, snow-laden Alps of my 1980s childhood starkly contrasts with today's dwindling winters…

    1 条评论
  • Aligning Business Strategies with Global Climate Goals

    Aligning Business Strategies with Global Climate Goals

    This week France announced possible jail terms for company directors who fail to fulfil the CSRD reporting requirements…

  • Sustainable Business: No Longer Optional

    Sustainable Business: No Longer Optional

    "Leaders who fail to understand this are not only wrong, they are also risking their very existence" Gone are the days…

  • Java Developer with Payments Experience (Leeds, UK)

    Java Developer with Payments Experience (Leeds, UK)

    We're hiring ! Infraxis AG delivers mission critical software, powering all kinds of electronic payments for major…

    1 条评论
  • Mondo Hackathon #3

    Mondo Hackathon #3

    This weekend Mondo Bank held their third Hackathon, opening up their incredible banking API to third party developers -…

    3 条评论
  • Mondo Hackathon 2

    Mondo Hackathon 2

    "What's my Mondo balance ?" Simon Vans-Collina was sitting right behind us. "What's the weather like ?" he said, to a…

    2 条评论
  • Mondo Hackathon

    Mondo Hackathon

    Infraxis is very much focused on the latest developments in payments interfaces and apps. Our products are designed to…

    2 条评论

社区洞察

其他会员也浏览了