On Thu, Apr 23, 2009 at 1:53 AM, aslak hellesoy wrote:
>
>
> Frankly, I don't think I'll ever implement a cute feature in Cucumber that
> allows you to have out of the box negation. It would be ugly no matter how
> it's done, and it would only save you a line or 2 of code.
>
fwiw, +1 on that. re
>
> Frankly, I don't think I'll ever implement a cute feature in Cucumber that
>> allows you to have out of the box negation. It would be ugly no matter how
>> it's done, and it would only save you a line or 2 of code.
>>
>
> fwiw, +1 on that. refactor to a descriptive method and get used to
> ref
Thanks for the response. I think I tried that one, still get the
response:
The 'Pollution' option was not found in the "temp_aspect_topic_id"
select box (Webrat::NotFoundError)
Any more thought?
Mike
___
rspec-users mailing list
rspec-users@rubyforge.
Thanks for the response. I think I tried that one, still get the
response:
The 'Pollution' option was not found in the "temp_aspect_topic_id"
select box (Webrat::NotFoundError)
Any more thought?
Mike
___
rspec-users mailing list
rspec-users@rubyforge.
On Thu, Apr 23, 2009 at 4:34 AM, mikej wrote:
> Thanks for the response. I think I tried that one, still get the
> response:
>
> The 'Pollution' option was not found in the "temp_aspect_topic_id"
> select box (Webrat::NotFoundError)
>
> Any more thought?
Do you only have one select box on the pa
>
> Then /^I (should|should not) see the people search form$/ do
> |should_or_should_not|
> expect_that(response, should_or_should_not, have_tag('form#frmSearch'))
> end
>
> def expect_that(target, should_or_should_not, matcher)
> target.send should_or_should_not.underscore.to_sym, matcher
> end
Another question: Where should metaclass.rb go; lib? lib/spec? or should
the method be put inside the spec_helper file?
--
Posted via http://www.ruby-forum.com/.
___
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinf
On Thu, Apr 16, 2009 at 10:35 AM, Matt Wynne wrote:
>
> On 16 Apr 2009, at 14:06, Joaquin Rivera Padron wrote:
>
>> thanks matt,
>> yes, the regexp in the step matcher is a good one to dry it up
>>
>> So I end up with this one:
>>
>> Then /^I (should|should not) see the people search form$/ do |ma
On Thu, Apr 23, 2009 at 9:39 AM, Ben Mabey wrote:
> David Chelimsky wrote:
>>
>> On Thu, Apr 16, 2009 at 10:35 AM, Matt Wynne wrote:
>>
>>>
>>> On 16 Apr 2009, at 14:06, Joaquin Rivera Padron wrote:
>>>
>>>
thanks matt,
yes, the regexp in the step matcher is a good one to dry it up
Hi there !
I was wondering if the way I test the validation of my forms is right or
not. So here's a little example :
Imagine you have a form with some validations designed to create some
object. You want to test it using Scenario Outline and Examples. So you fill
in the fields using , and press th
David Chelimsky wrote:
On Thu, Apr 16, 2009 at 10:35 AM, Matt Wynne wrote:
On 16 Apr 2009, at 14:06, Joaquin Rivera Padron wrote:
thanks matt,
yes, the regexp in the step matcher is a good one to dry it up
So I end up with this one:
Then /^I (should|should not) see the people search
On Thu, Apr 23, 2009 at 11:08 AM, James Byrne wrote:
> Another question: Where should metaclass.rb go; lib? lib/spec? or should
> the method be put inside the spec_helper file?
This is a utility for matchers to give good messages, so I'd put it in
lib/spec/matchers
I don't think we should call i
Rails definitely entices you to break Demeter's law just so often.
Now how to cleanly spec:
@comment = @article.comments.build(params[:comment]) ?
Mocking and stubbing is starting to get ugly now.
--
Posted via http://www.ruby-forum.com/.
___
rspec-u
On Thu, Apr 23, 2009 at 2:19 PM, Fernando Perez wrote:
> Rails definitely entices you to break Demeter's law just so often.
>
> Now how to cleanly spec:
>
> @comment = @article.comments.build(params[:comment]) ?
You think that's bad, I've seen many a code that looks like:
project.tasks.map(&:res
David Chelimsky wrote:
>
>
> I don't think we should call it metaclass though, but I'm not sure
> what I *do* want to call it. Metaclass != eigenclass, which is what
> this really is, so maybe eigenclass.rb - don't let that hang you up
> though, I can always change the names after.
>
The thing i
On Thu, Apr 23, 2009 at 1:56 PM, James Byrne wrote:
> David Chelimsky wrote:
>>
>>
>> I don't think we should call it metaclass though, but I'm not sure
>> what I *do* want to call it. Metaclass != eigenclass, which is what
>> this really is, so maybe eigenclass.rb - don't let that hang you up
>>
In one of my features I have to check to see if a file is created by an
external script and then determine if that file contains specific
information. So, I ended up with these step definitions:
When /currency exchange rate transfer file should contain rates/ do
found = false
fx_code = 'USD'
David Chelimsky wrote:
> On Thu, Apr 23, 2009 at 1:56 PM, James Byrne
> wrote:
>> for that method before extending Object with my own. If
>> Object.respond_to? :metaclass == true then we are in Rails, or some
>> other framework that provides the same thing, and so we need not provide
>> our own.
David Chelimsky wrote:
> I'd rather always define our own so the results are consistent from
> RSpec regardless of other frameworks in the midst. Does that make
> sense to you?
Instead of metaclass how about object_handle ?
wdt?
--
Posted via http://www.ruby-forum.com/.
On Thu, Apr 23, 2009 at 2:26 PM, James Byrne wrote:
> David Chelimsky wrote:
>
>> I'd rather always define our own so the results are consistent from
>> RSpec regardless of other frameworks in the midst. Does that make
>> sense to you?
>
> Instead of metaclass how about object_handle ?
>
> wdt?
G
On Thu, Apr 23, 2009 at 2:19 PM, Fernando Perez wrote:
> Rails definitely entices you to break Demeter's law just so often.
So fix it. It's usually just a matter of putting in some delegators.
If you don't like @article.comments.build, you can declare your own
Article.build_comment() method and
On Thu, Apr 23, 2009 at 12:05 PM, James Byrne wrote:
> When /currency exchange rate transfer file should contain rates/ do
> found = false
> fx_code = 'USD'
> File.open(FOREX_XFR_FN).each do |line|
> found = true if
> /.*fx_target#{fx_code}.*fx_rate(\d+\.\d{4}).*/.match(line)
> break if foun
David Chelimsky wrote:
> On Thu, Apr 23, 2009 at 2:26 PM, James Byrne
> wrote:
>> David Chelimsky wrote:
>>
>>> I'd rather always define our own so the results are consistent from
>>> RSpec regardless of other frameworks in the midst. Does that make
>>> sense to you?
>>
>> Instead of metaclass ho
On Thu, Apr 23, 2009 at 3:16 PM, James Byrne wrote:
> David Chelimsky wrote:
>> On Thu, Apr 23, 2009 at 2:26 PM, James Byrne
>> wrote:
>>> David Chelimsky wrote:
>>>
I'd rather always define our own so the results are consistent from
RSpec regardless of other frameworks in the midst. Do
Mark Wilden wrote:
> I find this more straighforward and easy to understand:
>
> When /currency exchange rate transfer file should contain rates/ do
> fx_code = 'USD'
> File.open(FOREX_XFR_FN).each do |line|
> return true if
> /.*fx_target#{fx_code}.*fx_rate(\d+\.\d{4}).*/.match(line)
>
On Thu, Apr 23, 2009 at 3:17 PM, David Chelimsky wrote:
> On Thu, Apr 23, 2009 at 3:16 PM, James Byrne wrote:
>> David Chelimsky wrote:
>>> On Thu, Apr 23, 2009 at 2:26 PM, James Byrne
>>> wrote:
David Chelimsky wrote:
> I'd rather always define our own so the results are consisten
On Thu, Apr 23, 2009 at 1:18 PM, James Byrne wrote:
> Mark Wilden wrote:
>
> > I find this more straighforward and easy to understand:
> >
> > When /currency exchange rate transfer file should contain rates/ do
> > fx_code = 'USD'
> > File.open(FOREX_XFR_FN).each do |line|
> > return tru
On Thu, Apr 23, 2009 at 3:59 PM, Mark Wilden wrote:
> On Thu, Apr 23, 2009 at 12:05 PM, James Byrne wrote:
>
>> When /currency exchange rate transfer file should contain rates/ do
>> found = false
>> fx_code = 'USD'
>> File.open(FOREX_XFR_FN).each do |line|
>> found = true if
>> /.*fx_target#{
On Thu, Apr 23, 2009 at 8:11 PM, Zach Dennis wrote:
> On Thu, Apr 23, 2009 at 3:59 PM, Mark Wilden wrote:
>> On Thu, Apr 23, 2009 at 12:05 PM, James Byrne wrote:
>>
>>> When /currency exchange rate transfer file should contain rates/ do
>>> found = false
>>> fx_code = 'USD'
>>> File.open(FOREX_
Done. Many thanks!
http://github.com/bmabey/cucumber-tmbundle/issues/#issue/1
Title: Support for Background (uh, Scenario?)
Body: Would like support (Text Highlighting, Code Snippet) for the
Cucumber "Background" key word. I'd imagine this would be a code
snippet just like Scenario. Best regards
David Chelimsky wrote:
> On Wed, Apr 22, 2009 at 2:09 PM, James Byrne
> wrote:
� � � (Spec::Expectations::ExpectationNotMetError)
>> Rates"
>> WDYT?
> I like the idea, though I think it's helpful to also have the strings
> in the case of String objects. But having the class and object id
> w
David Chelimsky wrote:
> On Thu, Apr 23, 2009 at 3:16 PM, James Byrne
> wrote:
>> to stick the object_handle method in the right place and get the revised
>> specs to pass. �I should have a patch for you tomorrow. If not, then by
>> Monday.
>
> Cool. I may need to get a release out before t
On 23 Apr 2009, at 17:03, Jérémy FRERE wrote:
Hi there !
I was wondering if the way I test the validation of my forms is
right or not. So here's a little example :
Imagine you have a form with some validations designed to create
some object. You want to test it using Scenario Outline and
I discovered this while debugging a RadiantCMS extension:
cucumber uses 'require' to load step definitions, _and_ since I loaded
the rails environment (in features/support/env.rb) for testing, _and_
radiant necessarily adds extensions to the load path, the path to
_every_ extension in your
34 matches
Mail list logo