Skip to content

Commit

Permalink
Update to version v6.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
estepamo-amazon committed Jun 6, 2024
1 parent 67b9413 commit ee4650f
Show file tree
Hide file tree
Showing 1,264 changed files with 65,622 additions and 87,896 deletions.
108 changes: 0 additions & 108 deletions .gitignore

This file was deleted.

207 changes: 0 additions & 207 deletions .nightswatch/deployment/taskcat.yml

This file was deleted.

28 changes: 27 additions & 1 deletion .nightswatch/functional/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def param_fetcher(region: str, stack_name: str) -> ParameterFetcher:

@pytest.fixture
def kendra_client(region: str, param_fetcher: ParameterFetcher) -> KendraClient:
return KendraClient(region, param_fetcher.get_kendra_index())
return KendraClient(region, param_fetcher.get_kendra_faq_index(), param_fetcher.get_kendra_webpage_index())

@pytest.fixture
def lex_client(region: str) -> LexClient:
Expand Down Expand Up @@ -127,6 +127,13 @@ def dom_operator():
yield dom_operator
dom_operator.end_session()

@pytest.fixture
def invalid_designer_login(dom_operator: DomOperator, param_fetcher: ParameterFetcher, username: str, password: str):
designer_url = param_fetcher.get_designer_url()
login_page = LoginPage(dom_operator, designer_url)
password = 'invalidPassword'
return login_page.login(username, password)

@pytest.fixture
def designer_login(dom_operator: DomOperator, param_fetcher: ParameterFetcher, username: str, password: str):
designer_url = param_fetcher.get_designer_url()
Expand All @@ -139,6 +146,13 @@ def client_login(dom_operator: DomOperator, param_fetcher: ParameterFetcher, use
login_page = LoginPage(dom_operator, client_url)
return login_page.login(username, password)

@pytest.fixture
def invalid_client_login(dom_operator: DomOperator, param_fetcher: ParameterFetcher, username: str, password: str):
client_url = param_fetcher.get_client_url()
login_page = LoginPage(dom_operator, client_url)
password = 'invalidPassword'
return login_page.login(username, password)

@pytest.fixture
def lambda_hook_example_arn(dom_operator: DomOperator, param_fetcher: ParameterFetcher, username: str, password: str) -> str:
return param_fetcher.get_lambda_hook_example_arn().split(':')[-1]
Expand All @@ -155,13 +169,25 @@ def log_timestamps(request):
def kendra_is_enabled(param_fetcher: ParameterFetcher):
return param_fetcher.kendra_is_enabled()


@pytest.fixture(autouse=True)
def skip_kendra(request, kendra_is_enabled):
if request.node.get_closest_marker('skipif_kendra_not_enabled'):
# if True:
if not kendra_is_enabled:
pytest.skip('Kendra is not configured for this environment. Skipping...')

@pytest.fixture
def knowledge_base_is_enabled(param_fetcher: ParameterFetcher):
return param_fetcher.bedrock_knowledge_base_is_enabled()

@pytest.fixture(autouse=True)
def skip_knowledge_base(request, knowledge_base_is_enabled):
if request.node.get_closest_marker('skipif_knowledge_base_not_enabled'):
# if True:
if not knowledge_base_is_enabled:
pytest.skip('Knowledge bases are not configured for this environment. Skipping...')

@pytest.fixture
def llm_is_enabled(param_fetcher: ParameterFetcher):
return param_fetcher.llm_is_enabled()
Expand Down
Loading

0 comments on commit ee4650f

Please sign in to comment.