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

Improved tests of Ad mortar projections #1263

Merged
merged 11 commits into from
Nov 18, 2024
Merged

Conversation

keileg
Copy link
Contributor

@keileg keileg commented Nov 17, 2024

Proposed changes

Changes:

  1. Created a file test_grid_operators.py and moved relevant tests to there from test_operators.py (the previous location did not follow the convention for test locations)
  2. Improved the tests for Ad mortar projections to cover subsets of grids and interfaces (previously only all subdomains and all interfaces of a Md-grid was considered), as well as mortar projections for non-matching grids.
  3. Some minor updates to the other tests, using functionality from applications rather than locally defined methods.

Currently, the tests of both subdomain and mortar projections is based on the same principle as the construction of the projections themselves (essentially stacking the matrices in the right order). This will however change with the implementation of #1182, and the current PR builds a much stronger foundation for that effort.

Types of changes

What types of changes does this PR introduce to PorePy?
Put an x in the boxes that apply.

  • Minor change (e.g., dependency bumps, broken links).
  • Bugfix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).
  • Testing (contribution related to testing of existing or new functionality).
  • Documentation (contribution related to adding, improving, or fixing documentation).
  • Maintenance (e.g., improve logic and performance, remove obsolete code).
  • Other:

Checklist

Put an x in the boxes that apply or explain briefly why the box is not relevant.

  • The documentation is up-to-date.
  • Static typing is included in the update.
  • This PR does not duplicate existing functionality.
  • The update is covered by the test suite (including tests added in the PR).
  • If new skipped tests have been introduced in this PR, pytest was run with the --run-skipped flag.

Copy link
Contributor

@IvarStefansson IvarStefansson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments only. Feel free to merge once addressed.

@keileg keileg merged commit de61d0f into develop Nov 18, 2024
5 checks passed
@keileg keileg deleted the improve_ad_grid_operator_tests branch November 18, 2024 10:45
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