Re: [rspec-users] Help with regexp in matcher

2009-01-16 Thread Matt Wynne
On 15 Jan 2009, at 22:13, James Byrne wrote: We have, in consequence, gone through and removed the term login from all code use as well; replacing it with authenticate. So, for example, the authentication form now says: To Proceed Please Authenticate Yourself I am sometimes (ok, mostly) sl

Re: [rspec-users] Help with regexp in matcher

2009-01-15 Thread aslak hellesoy
On Thu, Jan 15, 2009 at 11:13 PM, James Byrne wrote: > Matt Wynne wrote: > > > > > +1 to all that. I feel like you get lectured quite a bit by this list > > James, but you'd do well to heed the advice of some battle-hardened > > journeymen, IMO. > > > > I thought that you might like to know that,

Re: [rspec-users] Help with regexp in matcher

2009-01-15 Thread James Byrne
Matt Wynne wrote: > > +1 to all that. I feel like you get lectured quite a bit by this list > James, but you'd do well to heed the advice of some battle-hardened > journeymen, IMO. > I thought that you might like to know that, after reflecting on this overnight, I took this matter up in a desi

Re: [rspec-users] Help with regexp in matcher

2009-01-14 Thread James Byrne
Matt Wynne wrote: > > I actually rather like the unambiguous, and jargon-free 'current > authenticated session' phraseology, but I'm not one of your users, so > that doesn't really matter! I do too, but I am not the president either... > > I have one more suggestion. From all these different w

Re: [rspec-users] Help with regexp in matcher

2009-01-14 Thread Matt Wynne
On 13 Jan 2009, at 20:10, James Byrne wrote: Stephen Eley wrote: On Tue, Jan 13, 2009 at 10:41 AM, James Byrne wrote: Logins are a pervasive feature of this application Which is exactly why you should standardize. If you try to be accommodating toward unclear communication, you're just g

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread James Byrne
Stephen Eley wrote: > On Tue, Jan 13, 2009 at 10:41 AM, James Byrne > wrote: >> >> Logins are a pervasive feature of this application > > Which is exactly why you should standardize. If you try to be > accommodating toward unclear communication, you're just going to > create confusion when peop

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread Zach Dennis
On Tue, Jan 13, 2009 at 12:55 PM, Matt Wynne wrote: > > On 13 Jan 2009, at 17:14, Mark Wilden wrote: > >> On Tue, Jan 13, 2009 at 7:41 AM, James Byrne wrote: >> >> Logins are a pervasive feature of this application and so, rather than >> waste effort on policing the feature syntax, I thought it b

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread James Byrne
Matt Wynne wrote: . > > +1 to all that. I feel like you get lectured quite a bit by this list > James, but you'd do well to heed the advice of some battle-hardened > journeymen, IMO. > > I do hope that I do not give the impression that I resent anything that anyone has written in response to my

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread Matt Wynne
On 13 Jan 2009, at 17:14, Mark Wilden wrote: On Tue, Jan 13, 2009 at 7:41 AM, James Byrne wrote: Logins are a pervasive feature of this application and so, rather than waste effort on policing the feature syntax, I thought it best just to accommodate the likely variations from the start. P

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread Stephen Eley
On Tue, Jan 13, 2009 at 10:41 AM, James Byrne wrote: > > Logins are a pervasive feature of this application Which is exactly why you should standardize. If you try to be accommodating toward unclear communication, you're just going to create confusion when people need to get things done. Someon

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread aslak hellesoy
On Tue, Jan 13, 2009 at 6:14 PM, Mark Wilden wrote: > On Tue, Jan 13, 2009 at 7:41 AM, James Byrne wrote: > >> >> Logins are a pervasive feature of this application and so, rather than >> waste effort on policing the feature syntax, I thought it best just to >> accommodate the likely variations

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread Mark Wilden
On Tue, Jan 13, 2009 at 7:41 AM, James Byrne wrote: > > Logins are a pervasive feature of this application and so, rather than > waste effort on policing the feature syntax, I thought it best just to > accommodate the likely variations from the start. Premature flexibility is one of the roots o

Re: [rspec-users] Help with regexp in matcher

2009-01-13 Thread James Byrne
Thanks for all the advise and corrections. I ended up with this: When /\bsee a (?:log|sign)(?: ?)[io]n success message/ do # login | log in | logon | log on | signin ... Then "see the login ok message" end As to the issue of whether this is being too clever by half: Perhaps. I have to consi

Re: [rspec-users] Help with regexp in matcher

2009-01-12 Thread aslak hellesoy
On Mon, Jan 12, 2009 at 11:35 PM, Tim Glen wrote: > >> This is giving me an error: >> >> When /?:(log|sign)?:(i|o)n success message/ do >> Then "welcome message" >> end >> > > > I could be wrong, but I believe you're looking for this instead? > When /(?:log|sign)(?:i|o)n success message/ do > A

Re: [rspec-users] Help with regexp in matcher

2009-01-12 Thread Stephen Eley
On Mon, Jan 12, 2009 at 4:50 PM, James Byrne wrote: > > When /?:(log|sign)?:(i|o)n success message/ do > Then "welcome message" > end It's a syntax error on that first question mark, the one right after the slash. A ? in a regex signifies that whatever came just before it may appear 0 or 1 time

Re: [rspec-users] Help with regexp in matcher

2009-01-12 Thread Ben Mabey
On 1/12/09 2:50 PM, James Byrne wrote: This is giving me an error: When /?:(log|sign)?:(i|o)n success message/ do Then "welcome message" end The ?: needs to be inside your group if you don't want to capture it... so: When /(?:log|sign)(?:i|o)n success message/ do FWIW, I have found ht

Re: [rspec-users] Help with regexp in matcher

2009-01-12 Thread Tim Glen
This is giving me an error: When /?:(log|sign)?:(i|o)n success message/ do Then "welcome message" end I could be wrong, but I believe you're looking for this instead? When /(?:log|sign)(?:i|o)n success message/ do hope that helps, timg ___ rspec-u

[rspec-users] Help with regexp in matcher

2009-01-12 Thread James Byrne
This is giving me an error: When /?:(log|sign)?:(i|o)n success message/ do Then "welcome message" end To the effect that: /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require': ./features/components/login/step_definitions/login_steps.rb:21: invalid regular express