-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
52 additions
and
12 deletions.
There are no files selected for viewing
This file contains 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 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,13 @@ | ||
import pytest | ||
from click.testing import CliRunner | ||
|
||
from aiida.transports.transport import Transport as TransportClass | ||
|
||
@pytest.fixture | ||
def runner(): | ||
return CliRunner() | ||
|
||
original_exec_command_wait = TransportClass.exec_command_wait | ||
|
||
# TODO: Not yet implemented, seems hard to just use hq_env | ||
# If using real command, I need to handle the grace for teardown of tests |
This file contains 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,21 @@ | ||
import pytest | ||
from click.testing import CliRunner | ||
|
||
from aiida_hyperqueue.cli import cmd_install | ||
|
||
@pytest.fixture | ||
def runner(): | ||
return CliRunner() | ||
|
||
def test_install(runner, tmp_path, aiida_computer_ssh): | ||
aiida_computer_ssh(label="localhost-hq") | ||
|
||
version = "0.19.0" | ||
result = runner.invoke(cmd_install, ["-p", f"{str(tmp_path.resolve())}", "--hq-version", version, "--no-write-bashrc", "localhost-hq"]) | ||
|
||
assert result.exit_code == 0 | ||
assert f"hq version {version}" in result.output | ||
|
||
|
||
|
||
|
This file contains 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