Skip to content

Conversation

@jschroe212
Copy link

This uses the tests that came from first draft PR: #54 (comment)

@jschroe212
Copy link
Author

I ran the appraisal tests successfully on ruby 2.7.7 with these changes.

@westonganger
Copy link
Owner

westonganger commented Dec 8, 2022

Ok cool.

We need some more robust tests for this that check it with all options. We could likely do something similar to the kitchen sink tests for enumerator.

Also want to ensure that you manually verify the output of the tests in excel will be output to ./tmp/ folder.

Ideally we could have some automated test checking of XML contents, example

doc = parse_axlsx_package(p)
hyperlinks = doc.css("hyperlinks hyperlink")
assert_equal 2, hyperlinks.size
ref = "B1"
assert_equal ref, hyperlinks[0].attr("ref")
cell = doc.at("c[r='#{ref}']")
assert_equal "2", cell.text
assert_equal "inlineStr", cell.attr("t")
ref = "B2"
assert_equal ref, hyperlinks[1].attr("ref")
cell = doc.at("c[r='#{ref}']")
assert_equal url, cell.text
assert_equal "inlineStr", cell.attr("t")

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.

2 participants