March 3, 2017

Learning Serenity BDD: An Automation Framework That Uses Specification by Example (SBE)

When someone is demoing a new automation toolset for the very first time, so many questions in my mind start bubbling to to the surface:
  • This is an open-source tool? What grad student created it? What was the student attempting to achieve with this tool? What problems were they trying to solve?
  • Is the tool on GitHub? Unit tests and code samples provided for us novices learning the tool? 
  • What company supports it and sponsors it? Is the tool popular enough for a community to have built itself around the tool? 
  • Is the tool still being maintained? When was the last time code was checked into the GitHub repository? How many are watching and have starred the GitHub repository?
Although the contract position I start on Monday, begins as a manual testing position -- the best way to learn the system under test -- it'll move to an automation position using the tool Serenity BDD

Note: BDD stands for Behavior Driven Development. Read more about it in Introducing BDD ( Mar. 2006) by Dan North, the creator of JBehave, or on Martin Fowler's blog entry, GivenWhenThen (Aug. 2013).

Also, note: I haven't actually downloaded or installed the tool yet, or even tinkered with it. This is just me, an automation developer, attempting to do online researching, and compiling what I have found. I cannot make any recommendations about this tool and how easy or difficult to use. This is just gathering the initial research.


Serenity BDD Stats


Created by: John Ferguson Smart ( Website | Medium | LinkedIn | @Wakeleo )
Original name: Thucydides (See original blog, first post on Sept 2011 | Old GitHub repo )
Date created: Thucydides (2011) Serenity BDD (Nov. 2014)
Currently being maintained? Yes!
GitHubhttps://github.com/serenity-bdd/serenity-core
Official documentation: The Serenity Reference Manual, v. 1.0.1.1

Build systems: Gradle, Apache Maven, and even Apache Ant
Compatible frameworks:
Running tests remotely: Selenium Grid, Sauce Labs, Browser Stack
Tests that can be run: Web-based UI tests, API tests with REST Assured, and mobile tests with Appium

Serenity now comes in two flavors:
Information on Jan Molak: @JanMolakMediumLinkedIn

Who is John Ferguson Smart? 


According to John's website:

"John is an international speaker, consultant, author and trainer well known in the Agile community for his many books, articles and presentations, particularly in areas such as BDD, TDD, test automation, software craftsmanship and team collaboration. [...] John helps organisations and teams around the world deliver better software sooner through more effective collaboration and communication techniques, and through better technical practices.

"John is the author of the best-selling BDD in Action, as well as Jenkins: The Definitive Guide and Java Power Tools.

"Very active in the Open Source community, John also leads development on the innovative Serenity BDD test automation library, described as the 'best opensource selenium webdriver framework'". 


... John earned a Bachelor of Computer Science from Australia's University of Newcastle in 1991 and a PhD in Computer Science in 1995 from Aix-Marseille University in France.

John has published many articles on LinkedInMedium, and his own blog, relating to BDD, Serenity BDD, and his new idea of a screenplay pattern:

What Is The Philosophy of Serenity BDD?


From reading the documentation, tutorials, and watching many videos of Serenity BDD in action, it seems that the tool is all about one thing: Readability.
  • Readability of what, exactly the tests are doing.
  • Readability of the results of the tests, after they are run. 
As an automation developer, is very easy to get mired down in the code when using an automation framework. Is the automation code DRY (Don't Repeat Yourself), is it easy to maintain, and is it readable? How is the automation framework structured, is the architecture as good as it could be?

Most of the software development team, though, are not coders. How can you show the business analysts, the product owners about what the tests actually do, and what it means when the tests pass or fail?

John Ferguson Smart's solution was to use Specification By Example.

What Is Specification By Example?


Specification by example is a subject we have talked about in this blog back in January, mentioned by Agile Coach Greg Tutunjian when he spoke at a Ministry of Testing - Boston Meetup

Greg Tutunjian, during his talk, defined Specification by Example: (SBE) as "A collaboration method for specifying requirements and tests, Acceptance Test Driven Development (ATDD) and Behavior Driven Development (BDD)". 

The term was first seen in Martin Fowler's blog SpecificationByExample dated March 2004, 
"I was attending a workshop at XP/Agile Universe in 2002 when the phrase 'Specification By Example' struck me as a way to describe one of roles of testing in XP [...]
"Specification By Example isn't the way most of us have been brought up to think of specifications. Specifications are supposed to be general, to cover all cases. Examples only highlight a few points, you have to infer the generalizations yourself. This does mean that Specification By Example can't be the only requirements technique you use, but it doesn't mean that it can't take a leading role.
"[...] One of the great things about specification by example is that examples are usually much easier to come up with, particularly for the non-nerds who we write the software for".

What Is Serenity BDD?


Originally called Thucydides, named after the Ancient Greek historian who wrote History of the Peloponnesian War, Serenity BDD is an integrated test automation framework. From The Serenity Reference Manual, Introduction:

"Serenity BDD is an open source library that aims to make the idea of living documentation a reality.

"Serenity BDD helps you write cleaner and more maintainable automated acceptance and regression tests faster. Serenity also uses the test results to produce illustrated, narrative reports that document and describe what your application does and how it works. Serenity tells you not only what tests have been executed, but more importantly, what requirements have been tested.

"One key advantage of using Serenity BDD is that you do not have to invest time in building and maintaining your own automation framework.

"Serenity BDD provides strong support for automated web tests using Selenium 2, though it also works very effectively for non-web tests such as tests that exercise web services or even call application code directly.

"The aim of Serenity is to make it easy to quickly write well-structured, maintainable automated acceptance criteria, using your favorite BDD or conventional testing library. You can work with Behavior-Driven-Development tools like Cucumber or JBehave, or simply use JUnit. You can integrate with requirements stored in an external source (such as JIRA or any other test cases management tool), or just use a simple directory-based approach to organize your requirements".


Screenshot used in the Serenity Reference Guide.

Serenity BDD Demo:


Serenity BDD - Tutorial 1
John Ferguson Smart, May 2016



Serenity BDD Tutorial #2 - Introducing Screenplay
John Ferguson Smart, May 2016

What is the ScreenPlay Pattern?


From "Beyond Page Objects: Next Generation Test Automation with Serenity and the Screenplay Pattern" by John Ferguson Smart (March 2016)

"The Screenplay Pattern (formerly known as the Journey Pattern) is the application of SOLID design principles to automated acceptance testing, and helps teams address these issues. It is essentially what would result from the merciless refactoring of Page Objects using SOLID design principles. It was first devised by Antony Marcano between 2007 - 2008, refined with thinking from Andy Palmer from 2009. It didn’t receive the name 'the Journey Pattern' until Jan Molak started working with it in 2013. Several people have written about it under this name already, however, the authors now refer to it as the Screenplay Pattern.

"The Screenplay Pattern is an approach to writing high quality automated acceptance tests based on good software engineering principles such as the Single Responsibility Principle, and the Open-Closed Principle. It favours composition over inheritance, and employs thinking from Domain Driven Design to reflect the domain of performing acceptance tests, steering you towards the effective use of layers of abstraction. It encourages good testing habits and well-designed test suites that are easy to read, easy to maintain and easy to extend, enabling teams to write more robust and more reliable automated tests more effectively".


ScreenPlay: the next stage in automated acceptance testing
John Smart/Jan Molak, Nov 2016
https://www.youtube.com/watch?v=4eODK3WS6cM

Need Personalized Training?


Receive Personalized Training By The People Who Developed The Software! Advertised on John Ferguson Smart's site is Serenity BDD Mentoring Packages:

"Our tailored mentoring packages ensure that you get the most out of your Serenity BDD test automation suite, whether you are already a test automation veteran or you are entirely new to test automation in Java.

"Each mentoring package includes:
  • Support for up to 2 people for the smaller packages, and up to 4 people for the larger packages
  • An initial onsite visit to review the current tests and work with the team members
  • Regular remote pairing/mentoring sessions working on your production tests with up to 2 people working together on the same session
  • A monthly webinar covering Serenity best practices, news and updates
  • Exclusive access to premium training videos and resources
  • High priority email support for questions between mentoring sessions
"Above all, this program gives you a privileged access to the most authoritative source of information about Serenity BDD - the framework authors themselves, John Ferguson Smart and Jan Molak.

"Wakaleo Consulting can provide both training and full enterprise support for your Serenity BDD test framework, including help with installation, configuration and usage guidelines, as well as feature requests and custom integration work. We offer yearly support contracts backed with a service level agreement".

Need Even More Paid Training?


There is what John Smart calls a "Serenity Dojo", where over the course of nine months students of his dojo can scale a belt system, going from a white belt to black belt first by getting a personalized training packages from the library of fifty online videos, training workshops, and mentors.

"Onboarding: (4 to 6 weeks)
  • "Initiation: An initial 1-2 day workshop evaluates the team's current level and establish a tailored programme suited to the team's specific needs.
  • "Preparation: During the period leading up to the first immersion (typically around 4-6 weeks), team members become familiar with the online course material".
Immersion: (2 to 12 weeks)

"This phase uses individual and group workshops, mentoring, and active learning exercises to draw out the full potential of each team member, and to help them apply the practices to their own real- world projects.
  • "Workshops: One full week of face-to- face workshops helps participants validate and build on what they learnt during the onboarding. Progress is made visible and celebrated with formal grading and award ceremonies.
  • "Applied coaching: Assisted by their mentors, team members learn to apply what they have learnt to their real-world projects".
Accompaniment ( 6 to 9 months)

"After the immersion ends, teams go back to their routine. But the learning process doesn't stop there!
  • "Remote Mentoring: Team members continue to benefit from the support of their dedicated mentor, in the form of remote coaching and mentoring sessions.
  • "Followup workshops: Every 6 months the team members get to attend a followup immersion to help them further consolidate and expand their skills".


... Y'know, f I ever get into consulting, I need to remember this "software engineering education as marital arts" metaphor that I keep on seeing. Saying that I use Order and Discipline to write code is so much better than how I usually do things:
  • Randomly Googling stuff in a panic
  • Spending an evening feeling inferior studying other smarter and wiser developer's unit tests
  • Spending days trying to get a blasted tool to install on my environment
  • Writing code in fits and spurts
  • Searching StackOverflow for edge cases.
... Then again, I only have been coding on-the-job for a bit over two years. It gets better... right? Right?

And of course, thank you very much, John Smart for your words of encouragement!



Until Next Time, Happy Testing!



-T.J. Maher
Twitter | LinkedIn | GitHub

// Sr. QA Engineer, Software Engineer in Test, Software Tester since 1996.
// Contributing Writer for TechBeacon.
// "Looking to move away from manual QA? Follow Adventures in Automation on Facebook!"

462 comments:

«Oldest   ‹Older   401 – 462 of 462
메이저사이트 said...

Thank you a bunch for sharing this with all of us you actually realize what you are talking about! Bookmarked. Please also seek advice from my site =). We could have a hyperlink change contract between us 토토사이트

메이저사이트 said...

We conduct them through several anti-plagiarism checkers as well as spelling and grammar helpers online before the author submits them . Besides professional faculty essay authors, we've got a team of editors in place specifically for that function. By: 먹튀

MaxMockup said...

This is a great article thanks for sharing this information. I will visit your blog regularly for some latest post. Free Mockup

Click here for more said...

บาคาร่า เกมบาคาร่าออนไลน์ เป็นหนึ่งในเกมหาเงินที่เจมส์ บลอนด์เลือก เพราะเกมบาคาร่านั้นมีความซับซ้อน แต่ถึงอย่างนั้นก็สามารถเข้าใจได้Joint misery is an ordinary issue today. A gigantic level of the populace have report constant joint torture as a tremendous issue in their life. Many say that joint exacerbation is a critical avoidance on their ability to see the value throughout everyday life. A couple of examinations have recommended that it is a huge justification behind wretchedness (to try also decreased adaptability and robustness). Heres the best joint enhancements of the year 2022.

Joint wellbeing supplements address an instantly available and essential response for the inescapable issue of joint misery and sad convenientce.

Top type, expertly arranged joint items can sensationally affect the sufficiency of your joints. The best joint enhancements accessible today work to attack joint distress and appalling flexibility in a larger number of ways than one at the same time. This suggests they are planned to suit all requirements, no great explanation or earnestness of your joint issues.ง่าย best joint supplements 2022

Professional Course said...

Very useful message. This is my first time visiting here. I found a lot of interesting things on your blog, especially your discussion. It really is a great article. Keep on going.

Data Analytics Course in Ernakulam

sr said...

The scientific/botanical term for wild lettuce is “Lactusa Virosa.” It is a part of the Asteraceae plant family which has 23,600 species of herbs, shrubs, and trees throughout the world, making it a member of one the largest plant families worldwide. Two related plants to the Lactuca Virosa, are the Serriola Lactuca (also called the compass plant) and the Lactuca Canadensis (AKA Canada wild lettuce).

Wild lettuce grows in many regions of the world. In these regions, its presence is quite pervasive during the summer and early fall months. It can be found in backyards, along hiking trails, roadsides, growing up through the cracks in sidewalks, and almost anywhere else you can imagine. wild lettuce extract

Professional Course said...

Very interesting blog. A lot of the blogs I see these days don't provide anything that interests me, but I'm really interested in this one. I just thought I would post and let you know.

Data Science Course in Ernakulam

Professional Course said...

I couldn't leave your website until I told you that I really appreciated the high quality information it presents to your visitors. I will come back frequently to check for new posts.

Data Scientist Course in Durgapur

Professional Course said...

I am delighted to discover this page. I must thank you for the time you devoted to this particularly fantastic reading !! I really liked each part very much and also bookmarked you to see new information on your site.

Data Scientist Course in Ernakulam

Professional Course said...

I have read your article, it is very informative and useful to me, I admire the valuable information you offer in your articles. Thanks for posting it ...

Business Analytics Course in Ernakulam

먹튀사이트 said...

Many thanks for the article, I have a lot of spray lining knowledge but always learn something new. Keep up the good work and thank you again. 먹튀사이트

sohel said...

A highly-rated louisville web design , SEO, and digital marketing firm that provides affordable web and marketing solutions.

Johnson Hack said...


That was emphasized over and over again. That was how they presented health care cost reduction, that it would reduce the future costs. Not today, but it would reduce what we would pay in the future if we did nothing about it now.Eco gifts

Professional Course said...

I was very happy to find this site. I wanted to thank you for this excellent reading !! I really enjoy every part and have bookmarked you to see the new things you post.

Data Science Course in Durgapur

sohel said...

Freelancers Incubator is a European educational institution specializing in the field of freelancing and fersonal growth. Become a freelancer

슬롯사이트 said...

This is a very interesting post. Thank you for posting a lot of interesting posts. And please visit my site!~! The name of the site is 슬롯사이트 .

Downloadpc.co said...

After looking through a few blog articles on your website,
we sincerely appreciate the way you blogged.
PDF XChange Editor Plus Crack
Maxon Cinema 4D Studio Crack
VyprVPN Crack
CorelDraw Graphics Suite Crack

Unknown said...

Spectrum tv on firestick: Are you searching for the best cord-cutter to install and stream on your Firestick? Then you are in the right place. Yes, today I’m going to guide you on how to download and install Spectrum TV on Firestick?
I’m glad to inform you that Spectrum TV is one of the best streaming services to stream live TV channels and on-demand content on your Firestick. If you are wondering how to get rid of your cable services, continue reading the below guide. Come, let’s get into the content.

Unknown said...

I guess I am the only one who came here to share my very own experience. Guess what!? I am using my laptop for almost the past 2 year! but I had no idea of solving some basic issues. I do not know how to Crack Softwares Free Download But thankfully, I recently visited a website named vsthomes.com
crackpedia.net
crackpedia.net
crackpedia.net
crackpedia.net
Serif Affinity Photo Crack
Voicemod Pro crack
ESET Internet Security crack
PhpStorm crack
Foxit PhantomPDF Business crack

PCSOFTZ said...


I guess I am the only one who came here to share my very own experience. Guess what!? I am using my laptop for almost the past 2 years, but I had no idea of solving some basic issues. I do not know how to Download Latest PC Cracked Softwares But thankfully, I recently visited a website named pcsoftz.net
Adobe Photoshop Lightroom Crack
Icecream PDF Editor Pro crack
Tenorshare 4uKey For Android Crack
IOBIT Advanced SystemCare Pro Crack
XYplorer Pro Crack
K-Lite Mega Codec Pack Crack
Winstep Nexus Ultimate Crack
IObit Uninstaller Pro Crack

Professional Course said...

If you are looking for Illinois license plate sticker renewals online, you have to go to the right place. We have the fastest Illinois license plate sticker renewals in the state.

Data Science Course in Nagpur

arasukumar said...

Very nice job... Thanks for sharing this amazing and educative blog post!
Data Science Training in Lucknow

Nathan said...

Really impressed! Information shared was very helpful Your website is very valuable. Thanks for sharing.
Business Analytics Course in Bangalore

Dev Kumar said...

I read your excellent blog post. It's a great job. I enjoyed reading your post for the first time, thank you.
Data Science Institutes in Bangalore

슬롯커뮤니티 said...

슬롯커뮤니티

Professional Course said...

Really, this article is truly one of the best in article history. I am a collector of old "items" and sometimes read new items if I find them interesting. And this one that I found quite fascinating and should be part of my collection. Very good work!

Data Scientist Training in Bangalore

안전놀이터순위 said...

I'm so happy to finally find a post with what I want. 안전놀이터순위 You have inspired me a lot. If you are satisfied, please visit my website and leave your feedback.

ONcaino said...

Please keep on posting such quality articles as this is a rare thing to find these days. I am always searching online for posts that can help me. watching forward to another great blog. Good luck to the author! all the best! 스포츠토토사이트

Johnson Hack said...

I can set up my new thought from this post. It gives inside and out data. A debt of gratitude is in order for this profitable data for all,resource

Articlepins said...

Articlepins.com brings latest news, Trending news, Today news, General knowledge, Programming tutorials etc. >> Click Here To Visit Articlepins.com Here

EaglePie said...

Thanks for sharing this valuable information, we also provide instagram video download and,
really appreciate your hard work and good research that help us in for of your good valuable article. Keep updating us with your awesome content.

CasinoMecca said...

CasinoMecca

Royalcasino1016 said...

Royalcasino1016

Anonymous said...

I gotta favorite this website it seems very helpful ..You have a good point here!I totally agree with what you have said!!Thanks for sharing your views...hope more people will read this article!!..I admire this article for the well-researched content and excellent wording. I got so involved in this material that I couldn’t stop reading. I am impressed with your work and skill. Thank you so much. 토토사이트추천

Anonymous said...

Very likely I’m going to bookmark your blog . You absolutely have wonderful stories. Cheers for sharing with us your blog..Thank you for such a great article..Wow, excellent post. I'd like to draft like this too - taking time and real hard work to make a great article. This post has encouraged me to write some posts that I am going to write soon 먹튀검증

Anonymous said...

Quality content is the main to be a focus for the people to visit the web..page, that’s what this web site is providing.I am sure this paragraph has touched all the internet visitors,..its really really good piece of writing on building up new.Heya i’m for the primary time here. I came across this board and I find It really useful & it helped me out much. 안전놀이터

Anonymous said...

Newstyle Print offers high end, low cost banner printing in the UK.. like review goals which understand the cost of passing on the amazing strong asset futile out of pocket. I truly worshiped examining your posting. Grateful to you! 인디벳가입코드

Anonymous said...

This is cool post and i appreciate to peruse this post. your blog is incredible and you have great staff in your blog. decent sharing keep it up. More than a site, we are building a successful and redid propelled procedure. We urge, we support, we co-pilot ... Our main responsibility is to gain a result as per your objectives. I found very helpful information on your post, thanks for sharing with your great knowledge, I have bookmarked to you for future updates 안전놀이터

Anonymous said...

i am for the first time here. I found this board and I in finding It truly helpful & it helped me out a lot. I hope to present something back and help others such as you helped me. It is perfect time to make some plans for the future and it is time to be happy. I’ve read this post and if I could I desire to suggest you few interesting things or tips. Perhaps you could write next articles referring to this article. I want to read more things about it! 먹튀검증업체

Anonymous said...

This is truly a great read for me. I have bookmarked it and I am looking forward to reading new articles. Keep up the good work!...Fantastic blog! Do you have any tips and hints for aspiring writers? I’m planning to start my own website soon but I’m a little lost on everything. Would you propose starting with a free platform like WordPress or go for a paid option? There are so many options out there that I’m completely overwhelmed .. Any suggestions? Many thanks! 토토사이트

Anonymous said...

I am very enjoyed for this blog. Its an informative topic. It help me very much to solve some problems. Its opportunity are so fantastic and working style so speedy. The sims : Discover university is now available worldwide on PC! Your dorm room is ready for you, dom't be late for your first day of class 인터넷바카라

Anonymous said...

Set aside my effort to peruse every one of the remarks, however, I truly delighted in the article. It ended up being Very useful to me and I am certain to all the analysts here..Very interesting information!Perfect just what I was looking for!...This is truly a great read for me. I have bookmarked it and I am looking forward to reading new articles. Keep up the good work!. 메이저사이트

Anonymous said...

"Trying to say thank you won't simply be adequate, for the astonishing lucidity in your article. I will legitimately get your RSS to remain educated regarding any updates. Wonderful work and much accomplishment in your business endeavors .
Took me time to read all the comments, but I really enjoyed the article. It proved to be Very helpful to me and I am sure to all the commenters here! It’s always nice when you can not only be informed, but also entertained!" 안전놀이터

먹튀사이트 said...

Please let me know if you’re looking for a article writer for your site. You have some really great posts and I feel I would be a good asset. If you ever want to take some of the load off, I’d absolutely love to write some material for your blog in exchange for a link back to mine. Please send me an email if interested. Thank you 먹튀사이트 I couldn't think of this, but it's amazing! I wrote several posts similar to this one, but please come and see!!

먹튀검증 said...

Hey what a brilliant post I have come across and believe me I have been searching out for this similar kind of post for past a week and hardly came across this. Thank you very much and will look for more postings from you. 먹튀검증 and I am very happy to see your post just in time and it was a great help. Thank you ! Leave your blog address below. Please visit me anytime!

toomtbdf said...

betflix

saeed1681992@gmail.com said...

If you are interested in Android Apps, PC Software and MAC Applications then you can visit our official websites for registered applications that you can download full free without paying any charges.

Nexus Crack
PUBLIC CRACK
XYZ CRACK
ZROOT CRACKED
ZEE CHEAP

Django in Chains said...

Get a Quote

maiaharlow378 said...

How To Start 안전한놀이터 가입머니 주는 사이트 Missions In GTA Online

sam322657 said...

GTA Online: Some Players BANNED From Entering 먹튀사이트 먹튀검증사이트! Rockstar Explains Why & More!? (GTA 5 Online)

Royalcasino523 said...

Royalcasino523

안전한놀이터 said...

That's a really impressive new idea! 안전한놀이터 It touched me a lot. I would love to hear your opinion on my site. Please come to the site I run once and leave a comment. Thank you.

บาคาร่าออนไลน์ said...

Thank you for sharing one of these rights and healthful share with readers. May this post can be very useful and interesting for the readers who are in search of such a topic. Over again thanks for this put up.

ravensky867 said...

GTA Online 바둑이사이트 몰디브바둑이 Heist "The Big Con" 2-Players (Elite Challenge in Hard Mode)

bhanu said...

Thanks for sharing this information
Workday Online Course
Workday Online Training

Ehot Tub said...

Buy Hot Tubs and get the best deals at the lowest prices on ehottub.eu | lay-z-spa spa, Intex, Bestway, Mspa. Free delivery.

resource said...

The information that you discuss in the article is really helpful for me. Thanks for sharing. Thanks for sharing an article like this. The information that you discuss in the article is really helpful for me. Thanks for sharing. Thanks for sharing an article like this.

Carpenter Services in Delhi said...

I should say only that it's awesome! https://www.servicepik.com/carpenter-services-in-delhi/

Anonymous said...

I was looking for another article by chance and found your article 바카라게임사이트 I am writing on this topic, so I think it will help a lot. I leave my blog address below. Please visit once.

Let's Create Design said...

double bed and mattress

ravensky867 said...

로우바둑이 바둑이게임 Basics In Under 5 Minutes

Modafinila said...

Great Post.
armodafinil 150mg online to treat sleep issues.

«Oldest ‹Older   401 – 462 of 462   Newer› Newest»