Forum: Ruby on Rails noob help - creating a tests for a plugin

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
john (Guest)
on 2007-04-19 22:22

I have just created my first ever plugin and would like to write some
test's for it, any suggestions on where to start would be great.

I have this code in my site_test.rb file

require 'test/unit'
require File.dirname(__FILE__) + '/../lib/site'

class SiteTest < Test::Unit::TestCase
    include Site

    def test_getRegion


which I belive relates to this method

module Site
    def getRegion()
        oData =
        return oData.regionName

I was thinking that it may be possible to test that somthing is always
returned, how can this be done?

This topic is locked and can not be replied to.