Passing parameters to a shared context group?

46 views
Skip to first unread message

George Mendoza

unread,
Nov 18, 2015, 2:07:37 AM11/18/15
to rspec
Hello RSpec team,

Our team recently discovered that it's possible to pass parameters to a shared_context group. Is it safe to do so? I have read from the Difference between shared_examples and shared_context thread that shared_examples and shared_contexts are just aliases. However, AFAIK, passing parameters to a shared examples group is only documented for the shared examples group.

Thanks and more power!

George Mendoza
Philippines

Myron Marston

unread,
Nov 18, 2015, 2:12:28 AM11/18/15
to rs...@googlegroups.com
Yes, you can pass arguments to both, and it's completely safe to do so.

--
You received this message because you are subscribed to the Google Groups "rspec" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rspec+un...@googlegroups.com.
To post to this group, send email to rs...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rspec/aa709afa-c203-403a-9d55-1b22cfcca28e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

George Mendoza

unread,
Nov 18, 2015, 2:26:08 AM11/18/15
to rs...@googlegroups.com
That's cool. Thanks!

--
You received this message because you are subscribed to a topic in the Google Groups "rspec" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/rspec/MGgC2yQ5RKY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to rspec+un...@googlegroups.com.

To post to this group, send email to rs...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages