TDD and BDD in Ruby

Get Started with Ruby TDD, BDD and Unit Testing from scratch in 5 days.

Video Error

We tried several times to play your video but there was an unforeseen error. We have notified our engineers.

Visit https://helpx.adobe.com/flash-player.html to check that Flash is enabled on your browser.

With Flash enabled, please try again in a few minutes or contact support.

  • Lectures 16
  • Video 5 Hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion

How taking a course works

Discover

Find online courses made by experts from around the world.

Learn

Take your courses with you and learn anywhere, anytime.

Master

Learn and practice real-world skills and achieve your goals.

Course Description

If you are just coming into the Ruby community, you might think "man; everyone here does unit testing and TDD already". But the truth is, that is very far from reality. Most people in Ruby seem to talk the talk, but very few that I've seen actually walk the walk.

Yes, many of them do have tests, but very few do things test driven. It's just very difficult without a guiding hand sometimes. So many developers slack off and write the tests after.

Worst, many developers do not know how to write anything but integration tests. There is lots of good stuff in integration tests, but they can also be very slow for a good feedback cycle.

Unit testing is necessary to learn, and doing things test driven can make you more productive in the long run )I discuss some numbers during the course).

YOU DO NOT NEED ANY PREVIOUS UNIT TESTING EXPERIENCE.

I will teach you from zero how to write your first unit test with RSpec (and why RSpec) , all the way to making you a master of the craft with mock objects, stubs, and how to choose an isolation (mocking) framework.

You will also learn about making a continuous delivery solution and some patterns for getting started with a project on the right path.

Enjoy!

What are the requirements?

  • A ruby environment set up on your machine.

What am I going to get from this course?

  • Over 16 lectures and 5 hours of content!
  • Learn Unit Testing from absolute zero
  • Learn advanced concepts like Mocks, Stubs and Fakes
  • Learn Advanced RSpec techniques
  • Learn Continuous Delivery Techniques

What is the target audience?

  • Developers of all experience levels

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.

Curriculum

Section 1: Day 1 - Basic Building Blocks
48:03

What does the "Unit" in Unit Testing mean? Learn about the three end results of a "Unit" and how they relate to the three types of tests: Value Tests, State Tests and Interaction Tests with Mock Objects. Then we will jump into the basics of XUnit Frameworks.

21:35

Leanr how to set up a continuous testing solution using Guard and RSpec.

40:39

Now that we have continuous testing set up, we will work on the String Calculator Kata usiung RSpec.

09:32

Learn how to make your test code and production code simpler with some simple rules.

26:25

Common questions everyone asks when they see test driven development for the first time: Should I write many failing tests at the same time? what's the point of making the test fail first? these and more will be answered.

Section 2: Day 2 - Mocks, Stubs and Fakes
18:08

Learn the difference between Mocks, Stubs and Fakes, and use a hand written approach to creating Mock Objects.

15:24

Learn how to use Isolation (Mocking) frameworks and the difference between RSpec-Mocks, rr, Mocha and Bogus, and why Roy thinks Bogus is better.

Section 3: Day 3 - Advanced RSpec and Faking
25:44

We will now learn new features and advanced ideas to help clean up your RSpec files. Things like Subject, Let, specify, and more.

02:04

Learn how to fake class methods (statics) with Bogus.

5 pages

Please review the full day of Mock Objects videos before completing this lab.

Section 4: Day 4 - Acceptance Tests and Continuous Delivery
13:41

Learn how to use cucumber features to starting doing real Behavior Driven Development with your customer. BDD is all about communication, and here we learn the basics of writing the glue between what the customer or product owner writes, and what developers implement.

02:46

Learn how to use a gem like Capybara to test a simple sinatra application's main page.

Section 5: Day 5 - Continuous Delivery
25:05

Roy discusses how to start a project, and what goes into the first iteration. He then discusses the pyramid of resources, and how developers can say "no" by saying "yes" to features in the middle of an iteration.

40:26

In this talk we will set up a continuous integration solution for our project, that will run whenever we check things into github. We will talk about the different build configurations and build our first one.

09:41

Lastly, we will add dependancies between build configurations and make sure all builds use the same source and artifacts. This is the most important part about creating a build chain: making the build faster and source correct correct across the chain.

Section 6: Summary
00:46

Thank you very much for taking this course! You can learn more about unit testing at http://ArtOfUnitTesting.com

Instructor Biography

Roy Osherove, Author of 'The Art Of Unit Testing'

I run TDD and team leadership classes for software developers.

Roy Osherove is one of the original ALT. NET organizers. He consults and trains teams worldwide on the gentle art of unit testing, test-driven development and how to lead software teams. He frequently speaks at international conferences on these topics and others.

Roy is the author of the book The Art of Unit Testing, and writes about subjects such as unit testing, TDD Team Leadership and agile development on his blog

Join the biggest student community

14,000,000

Hours of video content

42,000,000

Course Enrollments

10,000,000

Students

Reviews

Average Rating
4.0
Details
  1. 5 Stars
    6
  2. 4 Stars
    2
  3. 3 Stars
    1
  4. 2 Stars
    1
  5. 1 Star
    1
Ready to start learning?
Preview This Course