Skip to content

Commit 7ba3c3c

Browse files
author
José Valim
committed
Revert "EEx tests aware of CR+LF newline on Windows"
This reverts commit f60d366.
1 parent 5158a19 commit 7ba3c3c

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

lib/eex/test/eex_test.exs

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -303,13 +303,13 @@ foo
303303
test "evaluates the source from a given file" do
304304
filename = Path.join(__DIR__, "fixtures/eex_template.eex")
305305
result = EEx.eval_file(filename)
306-
assert result == "foo bar." <> os_newline
306+
assert result == "foo bar.\n"
307307
end
308308

309309
test "evaluates the source from a given file with bindings" do
310310
filename = Path.join(__DIR__, "fixtures/eex_template_with_bindings.eex")
311311
result = EEx.eval_file(filename, [bar: 1])
312-
assert result == "foo 1" <> os_newline
312+
assert result == "foo 1\n"
313313
end
314314

315315
test "raises an Exception when there's an error with the given file" do
@@ -324,7 +324,7 @@ foo
324324
end
325325

326326
test "defined from file" do
327-
assert EExText.Compiled.file_sample(1) == "foo 1" <> os_newline
327+
assert EExText.Compiled.file_sample(1) == "foo 1\n"
328328
end
329329

330330
test "defined from file do not affect backtrace" do
@@ -356,13 +356,6 @@ foo
356356
}
357357
end
358358

359-
defp os_newline do
360-
case :os.type do
361-
{:win32, _} -> "\r\n"
362-
_ -> "\n"
363-
end
364-
end
365-
366359
defmodule TestEngine do
367360
@behaviour EEx.Engine
368361

0 commit comments

Comments
 (0)