#94 √ invalid
Phlip

merb-gen ... -T creates broken unit tests

Reported by Phlip | March 30th, 2008 @ 03:49 AM | in 1.0

http://rubyforge.org/pipermail/m...

excerpt:

When I generate a controller with option -T, I get a nice "functional" test

suite (meaning a suite that mocks a controller and a web server):

class GrepperTest < Test::Unit::TestCase

def setup

@controller = Grepper.build(fake_request)

@controller.dispatch('index')

end

  1. Replace this with your real tests.

def test_should_be_setup

assert false

end

end

However, 'rake test' does not mind the 'assert false' there. 'rake

test:functionals' does not exist, and 'ruby test/functional/grepper_test.rb'

produces "no such file to load -- test/functional/../test_helper".

Copying one in from

'app_generators/merb_plugin/templates/test/test_helper.rb' leads to

"uninitialized constant Test"

Comments and changes to this ticket

Please Login or create a free account to add a new comment.

You can update this ticket by sending an email to from your email client. (help)

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Shared Ticket Bins