Skip to content

Bob: Fix grammatical error in testdata#1319

Merged
rpottsoh merged 1 commit intoexercism:masterfrom
sshine:master
Sep 10, 2018
Merged

Bob: Fix grammatical error in testdata#1319
rpottsoh merged 1 commit intoexercism:masterfrom
sshine:master

Conversation

@sshine
Copy link
Copy Markdown
Contributor

@sshine sshine commented Sep 8, 2018

In the Bob exercise it says:

Bob's conversational partner is a purist when it comes to written
communication and always follows normal rules regarding sentence
punctuation in English.

But in the unit test the following input is fed to responseFor:

"\nDoes this cryogenic chamber make me look fat?\nno"

This is a rhetorical question, and by the expected value, this is deemed
to not be an actual question, which is very reasonable. But if Bob's
conversational partner is a punctuation purist, it should at least end
with a period.

I found this when exercising the Haskell track and wanting to grab the
last character that isPunctuation, but had to go with not . isSpace
(like the reference solution). But this really sounds wrong when I think
about it: I actually want the last punctuation character and am allowed
to assume "normal rules".

Making this change will not render not . isSpace solutions in the
Haskell track incorrect. I don't know what the implications are in other
language tracks that use this test case, and I don't know how to test
this.

@rpottsoh rpottsoh changed the title Bob's conversational partner is a purist! Bob: Fix grammatical error in testdata Sep 8, 2018
Copy link
Copy Markdown
Member

@rpottsoh rpottsoh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"version" needs to be updated. See README.md of this repo for more information.

@rpottsoh
Copy link
Copy Markdown
Member

rpottsoh commented Sep 8, 2018

Your proposed change to multiple line question looks fine to me.

@sshine
Copy link
Copy Markdown
Contributor Author

sshine commented Sep 8, 2018

Thank you for letting me know. I've bumped the MINOR version.

@rpottsoh
Copy link
Copy Markdown
Member

rpottsoh commented Sep 8, 2018

This PR should sit for at least another day to allow time for anyone that might want to comment.

To whomever merges this, the PR should be squashed as it is merged.

In the Bob exercise it says:

> Bob's conversational partner is a purist when it comes to written
> communication and always follows normal rules regarding sentence
> punctuation in English.

But in the unit test the following input is fed to `responseFor`:

    "\nDoes this cryogenic chamber make me look fat?\nno"

This is a rhetorical question, and by the expected value, this is deemed
to not be an actual question, which is very reasonable. But if Bob's
conversational partner is a punctuation purist, it should at least end
with a period.

I found this when exercising the Haskell track and wanting to grab the
last character that `isPunctuation`, but had to go with `not . isSpace`
(like the reference solution). But this really sounds wrong when I think
about it: I actually want the last punctuation character and am allowed
to assume "normal rules".

Making this change will not render `not . isSpace` solutions in the
Haskell track incorrect. I don't know what the implications are in other
language tracks that use this test case, and I don't know how to test
this.

Bump MINOR version of bob

Changing 'no' into 'No.' should be backwards-compatible.
@rpottsoh rpottsoh merged commit ca79943 into exercism:master Sep 10, 2018
@rpottsoh
Copy link
Copy Markdown
Member

@sshine thanks for taking the time to submit this PR and helping out Bob. 👍

petertseng pushed a commit to exercism/haskell that referenced this pull request Sep 12, 2018
In the Bob exercise it says:

> Bob's conversational partner is a purist when it comes to written
> communication and always follows normal rules regarding sentence
> punctuation in English.

But in the unit test the following input is fed to `responseFor`:

    "\nDoes this cryogenic chamber make me look fat?\nno"

This is a rhetorical question, and by the expected value, this is deemed
to not be an actual question, which is very reasonable. But if Bob's
conversational partner is a punctuation purist, it should at least be
"no." with the period.

I found this by wanting to grab the last character that `isPunctuation`,
but had to go with `not . isSpace` (like the reference solution). But
this really sounds wrong when I think about it: I actually want the last
punctuation character and am allowed to assume "normal rules".

Making this change will not render `not . isSpace` solutions wrong.

Bump test version to 1.4.0.7.

exercism/problem-specifications#1319
sshine added a commit to exercism/sml that referenced this pull request Oct 9, 2018
This includes:
 - 1.0.0 -> 1.1.0: "Calm down, I know what I'm doing!" in [1].
 - 1.1.0 -> 1.2.0: No-op in [2]
 - 1.2.0 -> 1.2.1: "no letters" in [3].
 - 1.2.1 -> 1.3.0: "I HATE THE DMV" in [4].
 - 1.3.0 -> 1.4.0: Grammatical error in testdata in [5].

[1]: exercism/problem-specifications#1025
[2]: exercism/problem-specifications#1056
[3]: exercism/problem-specifications#1282
[4]: exercism/problem-specifications#1293
[5]: exercism/problem-specifications#1319
ZapAnton added a commit to ZapAnton/rust that referenced this pull request Nov 20, 2018
Relevant PRs:
- exercism/problem-specifications#1282
- exercism/problem-specifications#1293
- exercism/problem-specifications#1319

Appart from the new tests, some old tests were renamed / got their input
value modified.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants