Offline, privacy-first grammar checker. Fast, open-source, Rust-powered
Merge branch 'master' of https://github.com/Automattic/harper into incase
hippietrail2f921460b30c
diff --cc harper-core/src/linting/phrase_corrections.rsindex a59a1333b,a3181f3d2..4037d42a2--- a/harper-core/src/linting/phrase_corrections.rs+++ b/harper-core/src/linting/phrase_corrections.rs@@@ -2201,12 -2202,48 +2208,57 @@@ mod tests);}+ #[test]+ fn correct_in_case() {+ assert_suggestion_result(+ "Support for enum variable incase of reusable enum class",+ lint_group(),+ "Support for enum variable in case of reusable enum class",+ );+ }+++ #[test]+ fn correct_worse_case_space() {+ assert_suggestion_result(+ "In the worse case scenario, remote code execution could be achieved.",+ lint_group(),+ "In the worst-case scenario, remote code execution could be achieved.",+ );+ }++ #[test]+ fn correct_worse_case_hyphen() {+ assert_suggestion_result(+ "Basically I want my pods to get the original client IP address... or at least have X-Forwarded-For header, in a worse-case scenario.",+ lint_group(),+ "Basically I want my pods to get the original client IP address... or at least have X-Forwarded-For header, in a worst-case scenario.",+ );+ }++ #[test]+ fn correct_worse_case_two_hyphens() {+ assert_suggestion_result(+ "In a worse-case-scenario, the scenario class code and the results being analysed, become out of sync, and so the wrong labels are applied.",+ lint_group(),+ "In a worst-case scenario, the scenario class code and the results being analysed, become out of sync, and so the wrong labels are applied.",+ );+ }++ #[test]+ fn correct_worst_case_space() {+ assert_suggestion_result(+ "The worst case scenario can be calculated without looking at streams of data.",+ lint_group(),+ "The worst-case scenario can be calculated without looking at streams of data.",+ );+ }++ #[test]+ fn correct_worst_case_two_hyphens() {+ assert_suggestion_result(+ "CAPD worst-case-scenario cloud simulator for naughty clouds.",+ lint_group(),+ "CAPD worst-case scenario cloud simulator for naughty clouds.",+ );+ }}