summaryrefslogtreecommitdiff
path: root/test/attributes_test.rb
diff options
context:
space:
mode:
authorDan Allen <dan.j.allen@gmail.com>2018-04-23 04:30:44 -0600
committerDan Allen <dan.j.allen@gmail.com>2018-04-23 23:58:46 -0600
commit69eaf1da081ec6f1b276b4efe76faebab8a49997 (patch)
treeadade4bc946cacf24c5b464dc21dd80857bfb162 /test/attributes_test.rb
parentd1d248ee6fdbef3588481abc3c530c269fc9eec0 (diff)
use cursor marks to track line numbers more accurately and efficiently
- add Reader#mark method to mark position of cursor (store internally) - add Reader#cursor_at_mark method to build Cursor from previously saved mark - mark position of cursor after reading block attribute lines in Parser.next_block - use Reader#cursor_at_mark to retrieve/record source location in Parser.next_block - add cursor option to Reader#read_lines_until so unterminated block warning reports start location of block - allow value of cursor option passed to Reader#read_lines_until to be :at_mark to read cursor from mark - update test assertions
Diffstat (limited to 'test/attributes_test.rb')
-rw-r--r--test/attributes_test.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/attributes_test.rb b/test/attributes_test.rb
index a9f8c13f..7993c09d 100644
--- a/test/attributes_test.rb
+++ b/test/attributes_test.rb
@@ -762,7 +762,7 @@ content
EOS
doc = document_from_string input
assert_nil doc.attr('hey')
- assert_message @logger, :WARN, '<stdin>: line 6: unterminated comment block', Hash
+ assert_message @logger, :WARN, '<stdin>: line 3: unterminated comment block', Hash
end
test 'substitutes inside block title' do