Upgrade to Pro — share decks privately, control downloads, hide ads and more …

How the RSpec team and I built the smooth upgrade process for RSpec 3

520b23dc9027ee642ea39a4c273fed7b?s=47 Yuji Nakayama
September 19, 2014

How the RSpec team and I built the smooth upgrade process for RSpec 3

Lightning Talk in RubyKaigi 2014

520b23dc9027ee642ea39a4c273fed7b?s=128

Yuji Nakayama

September 19, 2014
Tweet

Transcript

  1. How the RSpec team and I built the smooth upgrade

    process for RSpec 3 Yuji Nakayama @nkym37 yujinakayama
  2. RSpec 3 Released at June 2

  3. Your specs written on RSpec 2 cannot be run on

    RSpec 3 without upgrading
  4. The RSpec team and I made the upgrade process smooth

    as much as possible
  5. RSpec 2.99 Transpec by the RSpec team by me

  6. Compatible with RSpec 2.x + Deprecation warnings for things removed

    in 3.0 RSpec 2.99
  7. Upgrade checklist for your project You need not to read

    the entire changelog!
  8. Transpec Automatically converts your specs to the RSpec 3 syntax

  9. None
  10. AST Accurate conversion with

  11. + Runtime Information AST Accurate conversion with

  12. The Upgrade Process 1. Update RSpec from 2.x to 2.99

    2. Run Transpec 4. Update RSpec from 2.99 to 3.0 5. Done! 3. Manual handling (If any deprecation is remaining) About
  13. ? Is this upgrade approach applicable to other frameworks?

  14. Why it was possible in RSpec

  15. Simply Runnable Test codes are always run, so the deprecation

    warnings and the runtime analysis worked well.
  16. Specs themselves are tests. You can immediately notice if something

    is wrong. Testable
  17. It took much effort, but we had a significance of

    doing it for the many users. Popular
  18. ? So, ineffective in frameworks that don't meet the conditions?

    No There is room for compromise. It should still be helpful and much better than full manual upgrade.
  19. This approach might be an option for your framework

  20. How the RSpec team built the smooth upgrade process for

    RSpec 3 and I
  21. How the RSpec team built the smooth upgrade process for

    RSpec 3
  22. Thank you