Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
By, Jason Clark It’s a basic principle of testing that minimizing dependencies will make you happier, faster, and more productive. But what happens when you can’t? If your code plugs into or extends another gem, comfortable isolation might be out of the question. Stubbing and careful design can carry you a ways, but eventually you need to actually test your code against those gems you’re building on. Luckily, there are ways to reduce this pain. We’ll dig deep on creating a simple environment to check your work against multiple dependencies. We’ll see patterns that help avoid pulling your hair out when those dependencies change. We’ll even search around the raw edges, examining how to verify what your code does when it lands in an environment you haven’t tested. There’s a multitude of gems out there to build on. Let’s see how we can test with them! Help us caption & translate this video! http://amara.org/v/GUQI/
Date
Summarized using AI?
If this talk's summary was generated by AI, please check this box. A "Summarized using AI" badge will be displayed in the summary tab to indicate that the summary was generated using AI.
Show "Summarized using AI" badge on summary page
Summary
Markdown supported
In his presentation "Testing the Multiverse" at Ruby on Ales 2015, Jason Clark explores the complexities of testing code in Ruby when it involves multiple dependencies. He emphasizes that testing should aim to minimize dependencies to enhance productivity. However, when working with various versions of libraries, such as Ruby on Rails or other gems, developers face challenges in ensuring their code functions correctly across these versions. The key points of the presentation are as follows: - **Understanding the Multiverse**: The Multiverse refers to the scenario where a gem relies on other libraries, necessitating testing against multiple versions. - **The Programmer Input Output Ratio (Peor Metric)**: Clark introduces a fictional metric that measures developer productivity based on input-output ratios, although it is not formally part of the core libraries. - **Using Bundler Effectively**: He discusses creating multiple Gemfiles to manage dependencies across different versions and how to configure the `BUNDLE_GEMFILE` environment variable to run tests accordingly. - **Automation with Rake Tasks**: Clark describes utilizing Rake to automate the testing process across various versions and versions matching specific suffixes to streamline testing efforts. - **Dependency Management**: He stresses the importance of ensuring all necessary dependencies are installed and suggests running `bundle install` efficiently to avoid delays. - **Using Appraisal**: As a solution for managing multiple gemfile configurations, the Appraisal gem can simplify the process by defining appraisal files that declare differences from the base gemfile. - **Version Compatibility Challenges**: The presentation also covers how to manage backward compatibility and the implications of library updates, indicating the necessity of version checks and conditional test execution to ensure stability. - **Testing Strategies for Open Source**: Lastly, Clark discusses strategies for ensuring robust testing within different frameworks and libraries, like Kuner, demonstrating the need for clear and effective testing suites. By the end of the presentation, Clark encourages developers to adopt practices that ease the complexities of testing with multiple dependencies to become more effective and less frustrated. He provides practical techniques and insights aimed at improving the overall testing experience within the Ruby ecosystem.
Suggest modifications
Cancel