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

expect(RSpec::3).to be_coming_soon @Dius_AU Sep...

Jon Rowe
September 12, 2013

expect(RSpec::3).to be_coming_soon @Dius_AU September 2013

Repeat of my RSpec 3 talk given to DiusAU

Jon Rowe

September 12, 2013
Tweet

More Decks by Jon Rowe

Other Decks in Technology

Transcript

  1. .*...........*.*...................................................*..............*...............*..... ...........F....................*...........*.............*.*...........*...........F.*..............F. ..........FF...........**...........*...........**...........*.*..........................*........... *.*...................................................*..............*...............*................F.. ..................*...........*.............*.*...........*...........F.*..............F...........FF. ..........**...........*...........**...........*.*..........................*...........*.*.......... .........................................*..............*...............*................F................ ....*...........*.............*.*...........*...........F.*..............F...........FF...........** ...........*...........**...........*.*..........................*...........*.*....................... ............................*..............*...............*................F....................*.......

    ....*.............*.*...........*...........F.*..............F...........FF...........**...........* ...........**...........*.*..........................*...........*.*.................................... ...............*..............*...............*................F....................*...........*........ .....*.*...........*...........F.*..............F...........FF...........**...........*...........** ...........*.*..........................*...........*.*.................................................. .*..............*...............*................F....................*...........*.............*.*.... .......*...........F.*..............F...........FF...........**...........*...........**...........* .*..........................*...........*.*...................................................*.......... ....*...............*................F....................*...........*.............*.*...........*.... .......F.*..............F...........FF...........**...........*...........**...........*.*.......... ................*...........*.*...................................................*..............*....... ........*................F....................*...........*.............*.*...........*...........F.*.. ............F...........FF...........**...........*...........**...........*.*........................ ..*...........*.*...................................................*..............*...............*.... ............F....................*...........*.............*.*...........*...........F.*.............. F...........FF...........**...........*...........**...........*.*..........................*........ ...*.*...................................................*..............*...............*................ F....................*...........*.............*.*...........*...........F.*..............F........... FF...........**...........*...........**...........*.*..........................*...........*.*..... ..............................................*..............*...............*................F........... .........*...........*.............*.*...........*...........F.*..............F...........FF.......... .**...........*...........**...........*.*..........................*...........*.*................... ................................*..............*...............*................F....................*... ........*.............*.*...........*...........F.*..............F...........FF...........**......... expect(RSpec::3).to be_coming_soon JON ROWE Thursday, 12 September 13
  2. .*...........*.*...................................................*..............*...............*..... ...........F....................*...........*.............*.*...........*...........F.*..............F. ..........FF...........**...........*...........**...........*.*..........................*........... *.*...................................................*..............*...............*................F.. ..................*...........*.............*.*...........*...........F.*..............F...........FF. ..........**...........*...........**...........*.*..........................*...........*.*.......... .........................................*..............*...............*................F................ ....*...........*.............*.*...........*...........F.*..............F...........FF...........** ...........*...........**...........*.*..........................*...........*.*....................... ............................*..............*...............*................F....................*.......

    ....*.............*.*...........*...........F.*..............F...........FF...........**...........* ...........**...........*.*..........................*...........*.*.................................... ...............*..............*...............*................F....................*...........*........ .....*.*...........*...........F.*..............F...........FF...........**...........*...........** ...........*.*..........................*...........*.*.................................................. .*..............*...............*................F....................*...........*.............*.*.... .......*...........F.*..............F...........FF...........**...........*...........**...........* .*..........................*...........*.*...................................................*.......... ....*...............*................F....................*...........*.............*.*...........*.... .......F.*..............F...........FF...........**...........*...........**...........*.*.......... ................*...........*.*...................................................*..............*....... ........*................F....................*...........*.............*.*...........*...........F.*.. ............F...........FF...........**...........*...........**...........*.*........................ ..*...........*.*...................................................*..............*...............*.... ............F....................*...........*.............*.*...........*...........F.*.............. F...........FF...........**...........*...........**...........*.*..........................*........ ...*.*...................................................*..............*...............*................ F....................*...........*.............*.*...........*...........F.*..............F........... FF...........**...........*...........**...........*.*..........................*...........*.*..... ..............................................*..............*...............*................F........... .........*...........*.............*.*...........*...........F.*..............F...........FF.......... .**...........*...........**...........*.*..........................*...........*.*................... ................................*..............*...............*................F....................*... ........*.............*.*...........*...........F.*..............F...........FF...........**......... RSPEC 3 Thursday, 12 September 13
  3. RUBY 1.8.6 1.8.7 1.9.1 1.9.2 1.9.3 2.0.0 REE JRuby 1.8

    JRuby 1.9 Thursday, 12 September 13
  4. RUBY 1.8.6 1.8.7 1.9.1 1.9.2 1.9.3 2.0.0 REE JRuby 1.8

    JRuby 1.9 ~RBX 1.8 Thursday, 12 September 13
  5. RUBY 1.8.6 1.8.7 1.9.1 1.9.2 1.9.3 2.0.0 REE JRuby 1.8

    JRuby 1.9 ~RBX 1.8 ~RBX 1.9 Thursday, 12 September 13
  6. RUBY 1.8.7 1.9.2 1.9.3 2.0.0 REE JRuby 1.8 JRuby 1.9

    ~RBX 1.8 ~RBX 1.9 Thursday, 12 September 13
  7. Cleanup Removal of string evals Removal of workarounds for 1.8.6

    Remove Deprecations Thursday, 12 September 13
  8. Cleanup Removal of string evals Removal of workarounds for 1.8.6

    Remove Deprecations Extract Gems Thursday, 12 September 13
  9. Deprecations Spec stub! / unstub! mock / stub at_least(0) /

    any_number_of times Thursday, 12 September 13
  10. Deprecations Spec stub! / unstub! mock / stub at_least(0) /

    any_number_of times let/subject in before(:all) Thursday, 12 September 13
  11. Deprecations Spec stub! / unstub! mock / stub at_least(0) /

    any_number_of times let/subject in before(:all) should_not_receive(...).and_return Thursday, 12 September 13
  12. Changes New reporter / formatter API New shared_examples behaviour Block

    based DSL yield example Thursday, 12 September 13
  13. Changes New reporter / formatter API New shared_examples behaviour Block

    based DSL yield example Verifying doubles Thursday, 12 September 13
  14. shared_examples Currently shared examples are global Change to defined in

    context Cross nesting won’t be possible Thursday, 12 September 13
  15. DSL yields example Remove access to #example it { example

    } => NoMethodError Thursday, 12 September 13
  16. DSL yields example Remove access to #example it { example

    } => NoMethodError Changing to yielded to block it { |example| ... } let(:thing) { |example| ... } Thursday, 12 September 13
  17. Verifying Doubles Ported from rspec-fire (@xaviershay) Behave as normal in

    isolation Verify method signature when loaded Thursday, 12 September 13
  18. Verifying Doubles Ported from rspec-fire (@xaviershay) Behave as normal in

    isolation Verify method signature when loaded instance_double / class_double Thursday, 12 September 13
  19. Verifying Doubles Ported from rspec-fire (@xaviershay) Behave as normal in

    isolation Verify method signature when loaded instance_double / class_double as_stubbed_const Thursday, 12 September 13
  20. .*...........*.*...................................................*..............*...............*..... ...........F....................*...........*.............*.*...........*...........F.*..............F. ..........FF...........**...........*...........**...........*.*..........................*........... *.*...................................................*..............*...............*................F.. ..................*...........*.............*.*...........*...........F.*..............F...........FF. ..........**...........*...........**...........*.*..........................*...........*.*.......... .........................................*..............*...............*................F................ ....*...........*.............*.*...........*...........F.*..............F...........FF...........** ...........*...........**...........*.*..........................*...........*.*....................... ............................*..............*...............*................F....................*.......

    ....*.............*.*...........*...........F.*..............F...........FF...........**...........* ...........**...........*.*..........................*...........*.*.................................... ...............*..............*...............*................F....................*...........*........ .....*.*...........*...........F.*..............F...........FF...........**...........*...........** ...........*.*..........................*...........*.*.................................................. .*..............*...............*................F....................*...........*.............*.*.... .......*...........F.*..............F...........FF...........**...........*...........**...........* .*..........................*...........*.*...................................................*.......... ....*...............*................F....................*...........*.............*.*...........*.... .......F.*..............F...........FF...........**...........*...........**...........*.*.......... ................*...........*.*...................................................*..............*....... ........*................F....................*...........*.............*.*...........*...........F.*.. ............F...........FF...........**...........*...........**...........*.*........................ ..*...........*.*...................................................*..............*...............*.... ............F....................*...........*.............*.*...........*...........F.*.............. F...........FF...........**...........*...........**...........*.*..........................*........ ...*.*...................................................*..............*...............*................ F....................*...........*.............*.*...........*...........F.*..............F........... FF...........**...........*...........**...........*.*..........................*...........*.*..... ..............................................*..............*...............*................F........... .........*...........*.............*.*...........*...........F.*..............F...........FF.......... .**...........*...........**...........*.*..........................*...........*.*................... ................................*..............*...............*................F....................*... ........*.............*.*...........*...........F.*..............F...........FF...........**......... expect(monkey_patches). to be_close_to 0 Thursday, 12 September 13
  21. Monkey Patching Causes problems with conflicts Causes problems with internal

    state Clobbered by other monkeys Thursday, 12 September 13
  22. describe RSpec.describe do it “should not be monkey patchin’” do

    expect(monkey_patches).to be_close_to 0 end end Thursday, 12 September 13
  23. More Changes be_truthy / be_falsey receive_messages( msg: “val”, ... )

    No more integrated --debugger Thursday, 12 September 13
  24. More Changes be_truthy / be_falsey receive_messages( msg: “val”, ... )

    No more integrated --debugger New --dry-run mode Thursday, 12 September 13
  25. More Changes be_truthy / be_falsey receive_messages( msg: “val”, ... )

    No more integrated --debugger New --dry-run mode Less spammy deprecations Thursday, 12 September 13
  26. Summary No more 1.8.6 / 1.9.1 Less monkey patching (use

    expect) New reporters Thursday, 12 September 13
  27. Summary No more 1.8.6 / 1.9.1 Less monkey patching (use

    expect) New reporters New shared_example behaviour Thursday, 12 September 13
  28. Summary No more 1.8.6 / 1.9.1 Less monkey patching (use

    expect) New reporters New shared_example behaviour Cleaner, leaner, meaner! Thursday, 12 September 13
  29. .*...........*.*...................................................*..............*...............*..... ...........F....................*...........*.............*.*...........*...........F.*..............F. ..........FF...........**...........*...........**...........*.*..........................*........... *.*...................................................*..............*...............*................F.. ..................*...........*.............*.*...........*...........F.*..............F...........FF. ..........**...........*...........**...........*.*..........................*...........*.*.......... .........................................*..............*...............*................F................ ....*...........*.............*.*...........*...........F.*..............F...........FF...........** ...........*...........**...........*.*..........................*...........*.*....................... ............................*..............*...............*................F....................*.......

    ....*.............*.*...........*...........F.*..............F...........FF...........**...........* ...........**...........*.*..........................*...........*.*.................................... ...............*..............*...............*................F....................*...........*........ .....*.*...........*...........F.*..............F...........FF...........**...........*...........** ...........*.*..........................*...........*.*.................................................. .*..............*...............*................F....................*...........*.............*.*.... .......*...........F.*..............F...........FF...........**...........*...........**...........* .*..........................*...........*.*...................................................*.......... ....*...............*................F....................*...........*.............*.*...........*.... .......F.*..............F...........FF...........**...........*...........**...........*.*.......... ................*...........*.*...................................................*..............*....... ........*................F....................*...........*.............*.*...........*...........F.*.. ............F...........FF...........**...........*...........**...........*.*........................ ..*...........*.*...................................................*..............*...............*.... ............F....................*...........*.............*.*...........*...........F.*.............. F...........FF...........**...........*...........**...........*.*..........................*........ ...*.*...................................................*..............*...............*................ F....................*...........*.............*.*...........*...........F.*..............F........... FF...........**...........*...........**...........*.*..........................*...........*.*..... ..............................................*..............*...............*................F........... .........*...........*.............*.*...........*...........F.*..............F...........FF.......... .**...........*...........**...........*.*..........................*...........*.*................... ................................*..............*...............*................F....................*... ........*.............*.*...........*...........F.*..............F...........FF...........**......... QUESTIONS? Thursday, 12 September 13
  30. .*...........*.*...................................................*..............*...............*..... ...........F....................*...........*.............*.*...........*...........F.*..............F. ..........FF...........**...........*...........**...........*.*..........................*........... *.*...................................................*..............*...............*................F.. ..................*...........*.............*.*...........*...........F.*..............F...........FF. ..........**...........*...........**...........*.*..........................*...........*.*.......... .........................................*..............*...............*................F................ ....*...........*.............*.*...........*...........F.*..............F...........FF...........** ...........*...........**...........*.*..........................*...........*.*....................... ............................*..............*...............*................F....................*.......

    ....*.............*.*...........*...........F.*..............F...........FF...........**...........* ...........**...........*.*..........................*...........*.*.................................... ...............*..............*...............*................F....................*...........*........ .....*.*...........*...........F.*..............F...........FF...........**...........*...........** ...........*.*..........................*...........*.*.................................................. .*..............*...............*................F....................*...........*.............*.*.... .......*...........F.*..............F...........FF...........**...........*...........**...........* .*..........................*...........*.*...................................................*.......... ....*...............*................F....................*...........*.............*.*...........*.... .......F.*..............F...........FF...........**...........*...........**...........*.*.......... ................*...........*.*...................................................*..............*....... ........*................F....................*...........*.............*.*...........*...........F.*.. ............F...........FF...........**...........*...........**...........*.*........................ ..*...........*.*...................................................*..............*...............*.... ............F....................*...........*.............*.*...........*...........F.*.............. F...........FF...........**...........*...........**...........*.*..........................*........ ...*.*...................................................*..............*...............*................ F....................*...........*.............*.*...........*...........F.*..............F........... FF...........**...........*...........**...........*.*..........................*...........*.*..... ..............................................*..............*...............*................F........... .........*...........*.............*.*...........*...........F.*..............F...........FF.......... .**...........*...........**...........*.*..........................*...........*.*................... ................................*..............*...............*................F....................*... ........*.............*.*...........*...........F.*..............F...........FF...........**......... THANKS @jonrowe (Twitter, GitHub, etc) http://jonrowe.co.uk Thursday, 12 September 13