-
Notifications
You must be signed in to change notification settings - Fork 117
[wip] [feat] Add support for running interdependent tests with the serial execution policy #944
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
Closed
ChristopherBignamini
wants to merge
22
commits into
reframe-hpc:master
from
ChristopherBignamini:inter_depentent_check_unit_test
Closed
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
c6aa6ca
WIP Dependency unit testing development
ChristopherBignamini badd939
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini e7bb5d3
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini 9fbfb49
test cleanup procedure implemented with dependencies
ChristopherBignamini 548082c
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini 60d2156
Merge with master
ChristopherBignamini bca4959
Bug fixed
ChristopherBignamini 4a9cb19
Coding style fixes
ChristopherBignamini ba6b693
Updated number of loaded checks in unit tests and fixed dependency gr…
ChristopherBignamini ef9acf6
Dependency graph building moved into Runner class
ChristopherBignamini db06b16
Code cleaning
ChristopherBignamini 268f9e6
Cleanup with dependency tests moved
ChristopherBignamini 023b283
Code cleaning
ChristopherBignamini 75ae31d
Dependecies cleanup tests moved to new location
ChristopherBignamini 279757a
Code cleaning
ChristopherBignamini b3f726b
Code cleaning
ChristopherBignamini fcde831
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini 4346353
Coding style fix
ChristopherBignamini 5d9590c
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini b276f50
Merge branch 'master' into inter_depentent_check_unit_test
ChristopherBignamini 9ee4fb8
Coding style fixes
ChristopherBignamini f181c8b
Exception handling fix in cleanup procedure.
ChristopherBignamini File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,127 @@ | ||
| # | ||
| # Checks for testing the cleanup procedure with dependencies | ||
| # | ||
|
|
||
| import reframe as rfm | ||
| import reframe.utility.sanity as sn | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class DependencyT0(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo DependencyT0' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('DependencyT1') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class DependencyT1(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo DependencyT1' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('DependencyT2') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class DependencyT2(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo DependencyT2' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('DependencyT3') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class DependencyT3(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo DependencyT3' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT0(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT0' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('MultiDependencyT1') | ||
| self.depends_on('MultiDependencyT2') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT1(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT1' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('MultiDependencyT6') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT2(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT2' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('MultiDependencyT3') | ||
| self.depends_on('MultiDependencyT4') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT3(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT3' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('MultiDependencyT6') | ||
| self.depends_on('MultiDependencyT5') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT4(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT4' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
| self.depends_on('MultiDependencyT5') | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT5(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT5' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
|
|
||
|
|
||
| @rfm.simple_test | ||
| class MultiDependencyT6(rfm.RunOnlyRegressionTest): | ||
| def __init__(self): | ||
| self.local = True | ||
| self.executable = 'echo MultiDependencyT6' | ||
| self.sanity_patterns = sn.assert_found('Dependency', self.stdout) | ||
| self.valid_systems = ['*'] | ||
| self.valid_prog_environs = ['*'] | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| import unittest | ||
| from unittests.test_cli import TestFrontend | ||
|
|
||
|
|
||
| class TestCleanup(TestFrontend): | ||
| def test_dependency_cli(self): | ||
| self.checkpath = [ | ||
| 'unittests/resources/checks_unlisted/cleanup_checks.py'] | ||
| self.action = 'run' | ||
| self.more_options = ['-n', 'Dependency'] | ||
| returncode, stdout, _ = self._run_reframe() | ||
| self.assertIn('Running 4 check(s)', stdout) | ||
| self.assertEqual(0, returncode) | ||
|
|
||
| def test_multi_dependency_cli(self): | ||
| self.checkpath = [ | ||
| 'unittests/resources/checks_unlisted/cleanup_checks.py'] | ||
| self.action = 'run' | ||
| self.more_options = ['-n', 'MultiDependency'] | ||
| returncode, stdout, _ = self._run_reframe() | ||
| self.assertIn('Running 7 check(s)', stdout) | ||
| self.assertEqual(0, returncode) |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't
self.sourcesdir = Nonemissing from these tests?