HAL_90001
(HAL 9000)
24 September 2013 18:26
1
How can this occur?
This is output from an RSpec test...
expected: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/
got: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/
(using ==)
Any clue what I'm missing here?
Thanks,
Hal
Gives a good clue == vs #to_s /#inspect (visual inspection) may produce
different results. So you probably want to use #to_s or #inspect and then
test the strings.
John
···
On Tue, Sep 24, 2013 at 11:26 AM, Hal Fulton <rubyhacker@gmail.com> wrote:
How can this occur?
This is output from an RSpec test...
expected: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/
got: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/
(using ==)
check the encodings
This is why minitest says the following:
"No visible difference in the #{klass}#inspect output.\n",
"You should look at the implementation of #== on ",
"#{klass} or its members.\n",
···
On Sep 24, 2013, at 11:26 , Hal Fulton <rubyhacker@gmail.com> wrote:
How can this occur?
This is output from an RSpec test...
expected: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/
got: /<(?<tag>([[:alpha:]])+)>(?<cdata>(.)*)<\/\k<tag>>/ (using ==)