Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds two test cases that fail #8

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 24 additions & 1 deletion src/index.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,29 @@ const tests = [
expected:
"For I killed a man for my wound,\neven a young man for my bruise",
},
{
params: {
name: "",
bookId: "1PE",
ref: "1:24",
quote:
"πᾶσα σὰρξ ὡς χόρτος, καὶ πᾶσα δόξα αὐτῆς ὡς ἄνθος χόρτου. ἐξηράνθη ὁ χόρτος, καὶ τὸ ἄνθος ἐξέπεσεν,",
Copy link
Member Author

@richmahn richmahn Jan 16, 2025

Choose a reason for hiding this comment

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

Fails because of the period after χόρτου. If no period, or a new line is after the period, it will pass.

occurrence: 1,
},
expected: `All flesh {is} like grass,
and all its glory {is} like the flower of the grass.
The grass was dried up, and the flower fell off`,
},
{
params: {
name: "",
bookId: "1CO",
ref: "1:2",
quote: "τῇ ἐκκλησίᾳ τοῦ Θεοῦ & τῇ οὔσῃ ἐν Κορίνθῳ",
occurrence: 1,
},
expected: "to the church of God that is in Corinth",
Copy link
Member Author

@richmahn richmahn Jan 16, 2025

Choose a reason for hiding this comment

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

Is returning to the church & that is in Corinth, leaving out of God and replacing it with &.

Copy link
Member Author

Choose a reason for hiding this comment

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

If occurrence is -1, which is the default for many test cases, it will return the expected string for some reason.

}
];

describe("Find quotes", () => {
Expand Down Expand Up @@ -300,7 +323,7 @@ describe("Find quotes", () => {
try {
expect(targetQuotes).toEqual(expected);
} catch (e) {
console.log({ params, expected, received:targetQuotes, quoteMatches });
console.log({ params, expected, received: targetQuotes, quoteMatches });
throw e;
}
if (expectedSelections) {
Expand Down