Comments on: test-driven teaching /2009/08/test-driven-teaching/ Sarah Allen's reflections on internet software and other topics Wed, 24 Mar 2010 19:38:56 +0000 hourly 1 https://wordpress.org/?v=5.7.1 By: Hugo Baraúna /2009/08/test-driven-teaching/#comment-599 Wed, 24 Mar 2010 19:38:56 +0000 /?p=1963#comment-599 Interesting post. Do you already have any conclusions about how to approach teaching ruby/rails and TDD?

]]>
By: Test-Driven Teaching! « Find Time for the Karussell /2009/08/test-driven-teaching/#comment-598 Thu, 31 Dec 2009 15:45:39 +0000 /?p=1963#comment-598 […] Go to comments The idea of test-driven development (TDD) is not a new one and also the idea of test-driven teaching is not new (see also at springer or […]

]]>
By: learning through testing | the evolving ultrasaurus /2009/08/test-driven-teaching/#comment-597 Sat, 05 Sep 2009 17:03:57 +0000 /?p=1963#comment-597 […] as a response to my last post about test-driven teaching, Seth Walker told me about Ruby Koans, which are a delightful test-driven meditation on Ruby […]

]]>
By: ruby unit test frameworks | the evolving ultrasaurus /2009/08/test-driven-teaching/#comment-596 Mon, 31 Aug 2009 14:59:49 +0000 /?p=1963#comment-596 […] the evolving ultrasaurus Sarah Allen’s reflections on internet software and other topics Skip to content HomeCodeArchivesAbout « test-driven teaching […]

]]>
By: Jamie Flournoy /2009/08/test-driven-teaching/#comment-595 Mon, 24 Aug 2009 17:33:25 +0000 /?p=1963#comment-595 IMO it’s because of the output you get when the assertion fails.

a = 1
b = 2
assert a == b # failure message says ‘expected true but was false’
assert_equal a, b # failure message says ‘expected 1 but was 2’

The second failure message is more informative.

]]>
By: Sarah /2009/08/test-driven-teaching/#comment-594 Mon, 24 Aug 2009 17:10:00 +0000 /?p=1963#comment-594 The Ruby Koans are awesome. I went through the first two and plan to set aside some time to meditate on them every day. It does seem like such exercises would benefit from guidance from a Ruby Master. For example, in the following two koans:

  # To understand reality, we must compare our expectations against
  # reality.
  def test_assert_equality
    expected_value = 2
    actual_value = 1 + 1

    assert expected_value == actual_value
  end

  # Some ways of asserting equality are better than others.
  def test_a_better_way_of_asserting_equality
    expected_value = 2
    actual_value = 1 + 1

    assert_equal expected_value, actual_value
end

Why is it that assert_equal expected, actual is better than assert expected == actual? It seems that the latter is quite legible and arguably more readable.

]]>
By: seth /2009/08/test-driven-teaching/#comment-593 Mon, 24 Aug 2009 13:03:52 +0000 /?p=1963#comment-593 Hi Sarah,

The path to enlightenment (for ruby syntax at least): http://github.com/edgecase/ruby_koans/tree/master

]]>
By: Yehuda Katz /2009/08/test-driven-teaching/#comment-592 Mon, 24 Aug 2009 05:51:51 +0000 /?p=1963#comment-592 Matt Aimonetti and I taught a course on Merb in Phoenix earlier this year (January) using tests for teaching. We would introduce each new section with some tests, and ask the students to try to make them pass. It was extremely successful, because the students weren’t just trying our some hypothetical new technique, they had red/green to determine whether they were successful.

]]>
By: Revenge of the Link Roundup (August 17th, 2009) | Geek Feminism Blog /2009/08/test-driven-teaching/#comment-591 Mon, 17 Aug 2009 21:23:36 +0000 /?p=1963#comment-591 […] Sarah Mei, who teaches Ruby on Rails to women, posts about Test Driven Teaching […]

]]>