Open henrik opened 11 years ago
Also, it is of course a test smell to have an "and" there, but still, it's been known to happen :)
Some cases to consider:
it "should store and then destroy a foo"
it "should store a foo and a bar"
I may attempt a patch if you don't mind. A part-of-speech tagger like engtagger seems viable:
>> tgr.add_tags("it should store and then destroy a foo")
=> "<prp>it</prp> <md>should</md> <vb>store</vb> <cc>and</cc> <rb>then</rb> <vb>destroy</vb> <det>a</det> <nn>foo</nn>"
>> tgr.add_tags("should store a foo and a bar")
=> "<md>should</md> <vb>store</vb> <det>a</det> <nn>foo</nn> <cc>and</cc> <det>a</det> <nn>bar</nn>"
Patches are welcome!
On Thu, Jun 20, 2013 at 6:51 AM, Henrik Nyh notifications@github.comwrote:
I may attempt a patch if you don't mind. A part-of-speech tagger like engtagger https://github.com/yohasebe/engtagger seems viable:
tgr.add_tags("it should store and then destroy a foo") => "itshouldstoreandthendestroyafoo" tgr.add_tags("should store a foo and a bar") => "shouldstoreafooandabar"
— Reply to this email directly or view it on GitHubhttps://github.com/siyelo/should_clean/issues/6#issuecomment-19730822 .
Haven't considered edge cases – it may well be that any simple fix creates more of a mess than it fixes. But I wanted this listed among the issues, at least, even if it will be a wontfix.