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

Implemented ticket #329 and fixed authorized_keys #339

Merged
merged 55 commits into from
Jun 20, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
92d6a29
Implemented ticket #329 and fixed authorized_keys
ckunki Jun 6, 2023
34417ee
Updated changelog
ckunki Jun 6, 2023
a2eb031
removed stray parenthesis in test_cli_test_environment.py
ckunki Jun 6, 2023
e475c9e
Fixed some review findings
ckunki Jun 6, 2023
29e0617
Added generation of environment variable DATABASE_SSH_PORT incl. docu…
ckunki Jun 7, 2023
bfd28b3
Fixed review findings
ckunki Jun 7, 2023
d21dae5
fixed syntax error
ckunki Jun 7, 2023
af17e7a
fixed changelog
ckunki Jun 7, 2023
798da92
updated version number in file pyproject.toml
ckunki Jun 7, 2023
3f0c3b8
fixed test
ckunki Jun 7, 2023
2adeb4e
Added mandatory parameters to test case
ckunki Jun 7, 2023
28c18dd
changed class level property to method
ckunki Jun 9, 2023
bd1894f
changed default fort for SSH port forwarding to 20002
ckunki Jun 9, 2023
a1ae38a
fixed test
ckunki Jun 9, 2023
0faf96b
Fixed test
ckunki Jun 9, 2023
c323f28
Fixed test
ckunki Jun 9, 2023
7e0fe22
refactored class PortForwarding
ckunki Jun 12, 2023
fdecff0
updated files in eitde/docker_db_config/
ckunki Jun 12, 2023
9272968
Renamed class PortForwarding to Ports
ckunki Jun 12, 2023
403cb52
Updated user guide and fixes test
ckunki Jun 12, 2023
e5c45b0
Fixed review findings
ckunki Jun 12, 2023
b25078e
Updated changes file
ckunki Jun 12, 2023
704a229
Simplified tests for shell variables
ckunki Jun 12, 2023
844c877
removed unused property Ports.forward
ckunki Jun 12, 2023
77276cc
fixed syntax error
ckunki Jun 13, 2023
4b9a66c
fixed parameters for _connect_docker_network()
ckunki Jun 13, 2023
53dcc64
Fixed abstract_spawn_test_environment.py
ckunki Jun 13, 2023
6609885
Fixed abstract_spawn_test_environment.py
ckunki Jun 13, 2023
d060465
Fixed abstract_spawn_test_environment.py
ckunki Jun 13, 2023
32d7f8a
Merge branch 'main' into feature/329_forward_ssh_port
ckunki Jun 13, 2023
830cdfa
updated changelog.md
ckunki Jun 13, 2023
7c54baf
Fixed abstract_spawn_test_environment.py
ckunki Jun 13, 2023
1a66afa
Fixed abstract_spawn_test_environment.py
ckunki Jun 13, 2023
71a2d5a
fixed template for EXAConf in version 8.18.1
ckunki Jun 13, 2023
51b83e6
prefix environment variables with "ITDE" rather than "ENVIRONMENT"
ckunki Jun 14, 2023
5494032
changed ShellVariables to infer test_container_name from test_environ…
ckunki Jun 14, 2023
b03aea7
removed commented out import
ckunki Jun 14, 2023
d5bbe2f
fixed review findings.
ckunki Jun 14, 2023
70a54cc
Merge branch 'main' into feature/329_forward_ssh_port
ckunki Jun 15, 2023
a824b17
fixed merge error
ckunki Jun 15, 2023
6195a02
[run all tests]
ckunki Jun 15, 2023
a12d5eb
Moved container_named to test_ssh_access.py
ckunki Jun 15, 2023
8dda8c6
[run all tests]
ckunki Jun 15, 2023
8f7fd86
test with empty commit
ckunki Jun 19, 2023
d5b36c2
x
ckunki Jun 19, 2023
61e1e7b
x
ckunki Jun 19, 2023
83d5a13
x2
ckunki Jun 19, 2023
aecbe22
x3
ckunki Jun 19, 2023
b2f2d17
Merge branch 'main' into feature/329_forward_ssh_port
ckunki Jun 19, 2023
0a6e0f1
[run all tests]
ckunki Jun 19, 2023
caab992
fixed test_udf_execution.py
ckunki Jun 20, 2023
1647981
[run all tests]
ckunki Jun 20, 2023
9de3bea
fixed review finding
ckunki Jun 20, 2023
094f13d
changed import
ckunki Jun 20, 2023
307ec1f
[run all tests]
ckunki Jun 20, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 0 additions & 16 deletions test/integration/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,19 +101,3 @@ def create_context(
utils.close_environments(spawned)

return create_context


def exact_matcher(names):
return lambda value: all(x == value for x in names)


def superset_matcher(names):
return lambda value: all(x in value for x in names)


@contextlib.contextmanager
def container_named(*names, matcher=None):
matcher = matcher if matcher else exact_matcher(names)
with ContextDockerClient() as client:
matches = [c for c in client.containers.list() if matcher(c.name)]
yield matches[0] if matches else None
19 changes: 18 additions & 1 deletion test/integration/test_ssh_access.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,29 @@
import contextlib
import fabric
import io
import os
import pytest

from .conftest import container_named
from exasol_integration_test_docker_environment.lib.docker import ContextDockerClient
from exasol_integration_test_docker_environment.lib.base.ssh_access import SshKey, SshKeyCache


def exact_matcher(names):
ckunki marked this conversation as resolved.
Show resolved Hide resolved
return lambda value: all(x == value for x in names)


def superset_matcher(names):
return lambda value: all(x in value for x in names)


@contextlib.contextmanager
def container_named(*names, matcher=None):
matcher = matcher if matcher else exact_matcher(names)
with ContextDockerClient() as client:
matches = [c for c in client.containers.list() if matcher(c.name)]
yield matches[0] if matches else None


def test_generate_ssh_key_file(api_database):
params = { "db_os_access": "SSH" }
with api_database(additional_parameters=params) as db:
Expand Down