From 61b8db036bbee3f5d49ce1f1586ecc89cac7dff2 Mon Sep 17 00:00:00 2001 From: "Thomas A. Hirsch" Date: Mon, 23 Nov 2020 22:03:42 +0100 Subject: [PATCH] Added a test file and testcase for issue #831. --- tests/_files/source_without_newline.php | 1 + tests/tests/StaticAnalysis/CoveredFileAnalyserTest.php | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 tests/_files/source_without_newline.php diff --git a/tests/_files/source_without_newline.php b/tests/_files/source_without_newline.php new file mode 100644 index 000000000..7b04cff2b --- /dev/null +++ b/tests/_files/source_without_newline.php @@ -0,0 +1 @@ +assertEquals( + 1, + (new ParsingCoveredFileAnalyser(false, false))->linesOfCodeFor( + TEST_FILES_PATH . 'source_without_newline.php' + )->linesOfCode() + ); + } }