Skip to content

Add clojure.string-test.split-lines - #948

Merged
jeaye merged 4 commits into
jank-lang:mainfrom
djblue:split-lines
Jul 28, 2026
Merged

Add clojure.string-test.split-lines#948
jeaye merged 4 commits into
jank-lang:mainfrom
djblue:split-lines

Conversation

@djblue

@djblue djblue commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

No description provided.

(when-var-exists str/split-lines
(deftest test-split-lines
(testing "Normal use"
#?(:cljr (is (= [] (str/split-lines "")))

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@dmiller Is this an intended deviation?

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds a dedicated test namespace for clojure.string/split-lines, aligning it with the existing clojure.string-test.* coverage pattern in this test suite (feature-gated via when-var-exists for dialect/version portability).

Changes:

  • Introduces clojure.string-test.split-lines with “Normal use” assertions for common newline cases (\n, \r\n, leading/trailing newlines, multiple newlines).
  • Adds invalid-input exception expectations (non-CLJS) using the suite’s portable (p/thrown? …) assertion.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jeaye jeaye left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks, Chris!

Comment thread test/clojure/string_test/split_lines.cljc
Comment thread test/clojure/string_test/split_lines.cljc Outdated
@djblue
djblue requested a review from jeaye July 28, 2026 01:06

@jeaye jeaye left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Works for me!

@jeaye
jeaye merged commit afdcbf1 into jank-lang:main Jul 28, 2026
5 checks passed
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.

3 participants