Skip to content

Commit

Permalink
Revert "CART-831 TEST: add support for arbitrary envariables in yaml …
Browse files Browse the repository at this point in the history
…files (#4445)"

This reverts commit 1f76709.
  • Loading branch information
Sylvia Chan authored Mar 12, 2021
1 parent 82b5aaf commit 5cc48e4
Show file tree
Hide file tree
Showing 32 changed files with 131 additions and 217 deletions.
1 change: 0 additions & 1 deletion src/tests/ftest/cart/corpc/cart_corpc_five_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCoRpcFiveNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCoRpcFiveNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
15 changes: 7 additions & 8 deletions src/tests/ftest/cart/corpc/cart_corpc_five_node.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/corpc_prefwd
- D_LOG_MASK: "WARN,CORPC=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "0"
defaultENV:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/corpc_prefwd
D_LOG_MASK: "WARN,CORPC=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "0"
env_CRT_CTX_SHARE_ADDR: !mux
no_sep:
env: no_sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/corpc/cart_corpc_one_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCoRpcOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCoRpcOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
15 changes: 7 additions & 8 deletions src/tests/ftest/cart/corpc/cart_corpc_one_node.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
- D_LOG_MASK: "WARN,CORPC=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "16"
defaultENV:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
D_LOG_MASK: "WARN,CORPC=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "16"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/corpc/cart_corpc_two_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCoRpcTwoNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCoRpcTwoNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
15 changes: 7 additions & 8 deletions src/tests/ftest/cart/corpc/cart_corpc_two_node.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
- D_LOG_MASK: "WARN,CORPC=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "16"
defaultENV:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
D_LOG_MASK: "WARN,CORPC=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "16"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/ctl/cart_ctl_five_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCtlFiveNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCtlFiveNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
17 changes: 8 additions & 9 deletions src/tests/ftest/cart/ctl/cart_ctl_five_node.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/ctl
- D_LOG_MASK: "WARN"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "0"
- test_clients_CRT_CTX_NUM: "0"
defaultENV:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/ctl
D_LOG_MASK: "WARN"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "0"
test_clients_CRT_CTX_NUM: "0"
env_CRT_CTX_SHARE_ADDR: !mux
no_sep:
env: no_sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/ctl/cart_ctl_one_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCtlOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCtlOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
17 changes: 8 additions & 9 deletions src/tests/ftest/cart/ctl/cart_ctl_one_node.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/ctl
- D_LOG_MASK: "WARN"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "16"
- test_clients_CRT_CTX_NUM: "16"
defaultENV:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/ctl
D_LOG_MASK: "WARN"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "16"
test_clients_CRT_CTX_NUM: "16"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class CartCoRpcOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartCoRpcOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
- D_LOG_MASK: "WARN,RPC=DEBUG,HG=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "16"
defaultENV:
#!filter-only : /run/envs_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/corpc_prefwd
D_LOG_MASK: "WARN,RPC=DEBUG,HG=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "16"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/group_test/group_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ class GroupTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(GroupTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
11 changes: 5 additions & 6 deletions src/tests/ftest/cart/group_test/group_test.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/tests/no_pmix_launcher
- D_LOG_MASK: "WARN,RPC=DEBUG,HG=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
defaultENV:
#!filter-only : /run/tests/no_pmix_launcher
D_LOG_MASK: "WARN,RPC=DEBUG,HG=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
hosts: !mux
hosts_1:
config: one_node
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/iv/cart_iv_one_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ class CartIvOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartIvOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
17 changes: 8 additions & 9 deletions src/tests/ftest/cart/iv/cart_iv_one_node.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/iv
- D_LOG_MASK: "WARN,IV=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "2"
- test_clients_CRT_CTX_NUM: "2"
defaultENV:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/iv
D_LOG_MASK: "WARN,IV=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "2"
test_clients_CRT_CTX_NUM: "2"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
1 change: 0 additions & 1 deletion src/tests/ftest/cart/iv/cart_iv_two_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ class CartIvTwoNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartIvTwoNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand Down
17 changes: 8 additions & 9 deletions src/tests/ftest/cart/iv/cart_iv_two_node.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/iv
- D_LOG_MASK: "WARN,IV=DEBUG"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- test_servers_CRT_CTX_NUM: "2"
- test_clients_CRT_CTX_NUM: "2"
defaultENV:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/no_sep
#!filter-only : /run/tests/iv
D_LOG_MASK: "WARN,IV=DEBUG"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
test_servers_CRT_CTX_NUM: "2"
test_clients_CRT_CTX_NUM: "2"
env_CRT_CTX_SHARE_ADDR: !mux
sep:
env: sep
Expand Down
40 changes: 16 additions & 24 deletions src/tests/ftest/cart/no_pmix/cart_nopmix_multictx_one_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,8 @@

import sys
import subprocess
import os

from apricot import TestWithoutServers
from apricot import TestWithoutServers

sys.path.append('./util')

Expand All @@ -28,8 +27,17 @@ class CartNoPmixOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartNoPmixOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)
crt_phy_addr = self.params.get("CRT_PHY_ADDR_STR", '/run/defaultENV/')
ofi_interface = self.params.get("OFI_INTERFACE", '/run/defaultENV/')
ofi_ctx_num = self.params.get("CRT_CTX_NUM", '/run/defaultENV/')
ofi_share_addr = self.params.get("CRT_CTX_SHARE_ADDR",
'/run/defaultENV/')
self.pass_env = {"CRT_PHY_ADDR_STR": crt_phy_addr,
"OFI_INTERFACE": ofi_interface,
"CRT_CTX_SHARE_ADDR": ofi_share_addr,
"CRT_CTX_NUM": ofi_ctx_num}

def tearDown(self):
""" Tear down """
Expand All @@ -44,31 +52,11 @@ def test_cart_no_pmix(self):
:avocado: tags=all,cart,pr,daily_regression,no_pmix,one_node
"""

crt_phy_addr = os.environ.get("CRT_PHY_ADDR_STR")
ofi_interface = os.environ.get("OFI_INTERFACE")
ofi_ctx_num = os.environ.get("CRT_CTX_NUM")
ofi_share_addr = os.environ.get("CRT_CTX_SHARE_ADDR")

# env dict keys and values must all be of string type
if not isinstance(crt_phy_addr, ("".__class__, u"".__class__)):
crt_phy_addr = ""
if not isinstance(ofi_interface, ("".__class__, u"".__class__)):
ofi_interface = ""
if not isinstance(ofi_ctx_num, ("".__class__, u"".__class__)):
ofi_ctx_num = ""
if not isinstance(ofi_share_addr, ("".__class__, u"".__class__)):
ofi_share_addr = ""

pass_env = {"CRT_PHY_ADDR_STR": crt_phy_addr,
"OFI_INTERFACE": ofi_interface,
"CRT_CTX_SHARE_ADDR": ofi_share_addr,
"CRT_CTX_NUM": ofi_ctx_num}

cmd = self.params.get("tst_bin", '/run/tests/*/')

self.utils.print("\nTest cmd : %s\n" % cmd)

test_env = pass_env
test_env = self.pass_env
p = subprocess.Popen([cmd], env=test_env, stdout=subprocess.PIPE)

rc = self.utils.wait_process(p, 30)
Expand All @@ -78,3 +66,7 @@ def test_cart_no_pmix(self):
self.fail("Test failed.\n")

self.utils.print("Finished waiting for {}".format(p))


if __name__ == "__main__":
main()
16 changes: 7 additions & 9 deletions src/tests/ftest/cart/no_pmix/cart_nopmix_multictx_one_node.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
# change host names to your reserved nodes, the
# required quantity is indicated by the placeholders

ENV:
default:
#!filter-only : /run/env_CRT_CTX_SHARE_ADDR/sep
#!filter-only : /run/tests/rpc_error
- D_LOG_MASK: "WARN"
- CRT_PHY_ADDR_STR: "ofi+sockets"
- OFI_INTERFACE: "eth0"
- CRT_CTX_NUM: "8"
- CRT_CTX_SHARE_ADDR: "0"
defaultENV:
#!filter-only : /run/tests/no_pmix_multi_ctx
D_LOG_MASK: "WARN"
CRT_PHY_ADDR_STR: "ofi+sockets"
OFI_INTERFACE: "eth0"
CRT_CTX_NUM: "8"
CRT_CTX_SHARE_ADDR: "0"
tests: !mux
no_pmix_multi_ctx:
name: no_pmix_multi_ctx
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

from __future__ import print_function

import os
import sys

from apricot import TestWithoutServers
Expand All @@ -27,7 +26,6 @@ class CartNoPmixLauncherOneNodeTest(TestWithoutServers):
def setUp(self):
""" Test setup """
print("Running setup\n")
super(CartNoPmixLauncherOneNodeTest, self).setUp()
self.utils = CartUtils()
self.env = self.utils.get_env(self)

Expand All @@ -47,10 +45,10 @@ def test_cart_no_pmix_launcher(self):
cli_bin = self.params.get("test_clients_bin", '/run/tests/*/')
cli_arg = self.params.get("test_clients_arg", '/run/tests/*/')
cli_ppn = self.params.get("test_clients_ppn", '/run/tests/*/')

log_mask = os.environ.get("D_LOG_MASK")
crt_phy_addr = os.environ.get("CRT_PHY_ADDR_STR")
ofi_interface = os.environ.get("OFI_INTERFACE")
log_mask = self.params.get("D_LOG_MASK", "/run/defaultENV/")
crt_phy_addr = self.params.get("CRT_PHY_ADDR_STR",
"/run/defaultENV/")
ofi_interface = self.params.get("OFI_INTERFACE", "/run/defaultENV/")

srv_cmd = self.utils.build_cmd(self, self.env, "test_servers")

Expand Down
Loading

0 comments on commit 5cc48e4

Please sign in to comment.