Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tests for data-section-header column names #466

Merged

Conversation

dcslagel
Copy link
Collaborator

@dcslagel dcslagel commented May 18, 2021

Description:

This pull-request adds tests for the data-header-line branch change. This duplicates the examples in data-section-header.ipynb at https://gist.github.com/kinverarity1/aaf3459c3fa3eeafe127c9011c15c835.

tests/test_write.py::test_write_data_section_header_default
tests/test_write.py::test_write_data_section_header_with_curve_names
tests/test_write.py::test_write_data_section_header_renamed_with_curve_names 

The edge cases described in #375 are not covered in these tests:

  • where mnemonics are missing from the ~C section, there should be the appropriate lasio-generated UNKNOWN mnemonic in the ~A header row only (not in the ~C section)
  • where duplicate mnemonics exist, the ~A header row should contain these as duplicates, NOT the lasio-generated GAMM[1], GAMM[2] etc with suffixes
  • where mnemonics are longer than the specified write fmt, the width of the column in the data section will need to be increased to cater for the increased length of the mnemonic
  • when the data section is wrapped, specifying mnemonics_header_row=True should revert to False, and a logger.warning call made to inform the user/application that this doesn't work.

@kinverarity1
Copy link
Owner

Thank you!

@kinverarity1 kinverarity1 merged commit 3a28fbe into kinverarity1:data-header-line May 18, 2021
@dcslagel dcslagel deleted the data-header-line-tests branch May 18, 2021 15:27
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