Skip to content

Commit

Permalink
Merge pull request #26 from caponetto/fix-ci
Browse files Browse the repository at this point in the history
Fixes to get a green CI
  • Loading branch information
etirelli authored Aug 27, 2024
2 parents 2ccb3c9 + 421ac9e commit 196f35c
Show file tree
Hide file tree
Showing 12 changed files with 104 additions and 210 deletions.
2 changes: 1 addition & 1 deletion cypress.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"supportFile": "./tests/support/commands.ts",
"pluginsFile": "./tests/plugins/index.ts",
"screenshotsFolder": "./build/cypress-tests/screenshots",
"video": false,
"video": true,
"videosFolder": "./build/cypress-tests/videos",
"videoUploadOnPasses": false,
"fixturesFolder": false,
Expand Down
2 changes: 1 addition & 1 deletion elyra/metadata/schemas/kfp.json
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@
"title": "Cloud Object Storage Endpoint",
"description": "The Cloud Object Storage endpoint",
"type": "string",
"pattern": "^((?:https?:\\/\\/)?[^./]+(?:\\.[^./]+)+(?:\\/.*)?)$",
"pattern": "^(https?:\\/\\/)?([a-zA-Z0-9-]+(\\.[a-zA-Z0-9-]+)*)(:\\d+)?(\\/.*)?$",
"uihints": {
"category": "Cloud Object Storage",
"ui:placeholder": "https://your-cos-service:port"
Expand Down
2 changes: 1 addition & 1 deletion elyra/pipeline/processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ def _upload_dependencies_to_object_store(
raise ex from ex

def _verify_cos_connectivity(self, runtime_configuration) -> None:
if not runtime_configuration.metadata["cos_endpoint"].startswith("https://"):
if not runtime_configuration.metadata["cos_endpoint"].startswith(("https://", "http://")):
runtime_configuration.metadata["cos_endpoint"] = "https://" + runtime_configuration.metadata["cos_endpoint"]
self.log.debug(
"Verifying cloud storage connectivity using runtime configuration "
Expand Down
9 changes: 9 additions & 0 deletions elyra/tests/cli/test_pipeline_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -1079,6 +1079,9 @@ def test_export_incompatible_runtime_config(kubeflow_pipelines_runtime_instance,


@pytest.mark.parametrize("catalog_instance_no_server_process", [KFP_COMPONENT_CACHE_INSTANCE], indirect=True)
@pytest.mark.skip(
reason="This test is not compatible with KFP v2: It relies on incompatible assets from elyra-examples-kfp-catalog lib. See https://github.com/elyra-ai/examples/issues/115" # noqa: E501
)
def test_export_kubeflow_output_option(
jp_environ, kubeflow_pipelines_runtime_instance, catalog_instance_no_server_process
):
Expand Down Expand Up @@ -1229,6 +1232,9 @@ def test_export_airflow_output_option(airflow_runtime_instance):


@pytest.mark.parametrize("catalog_instance_no_server_process", [KFP_COMPONENT_CACHE_INSTANCE], indirect=True)
@pytest.mark.skip(
reason="This test is not compatible with KFP v2: It relies on incompatible assets from elyra-examples-kfp-catalog lib. See https://github.com/elyra-ai/examples/issues/115" # noqa: E501
)
def test_export_kubeflow_overwrite_option(
jp_environ, kubeflow_pipelines_runtime_instance, catalog_instance_no_server_process
):
Expand Down Expand Up @@ -1322,6 +1328,9 @@ def test_export_airflow_format_option(airflow_runtime_instance):


@pytest.mark.parametrize("catalog_instance_no_server_process", [KFP_COMPONENT_CACHE_INSTANCE], indirect=True)
@pytest.mark.skip(
reason="This test is not compatible with KFP v2: It relies on incompatible assets from elyra-examples-kfp-catalog lib. See https://github.com/elyra-ai/examples/issues/115" # noqa: E501
)
def test_export_kubeflow_format_option(
jp_environ, kubeflow_pipelines_runtime_instance, catalog_instance_no_server_process
):
Expand Down
201 changes: 82 additions & 119 deletions elyra/tests/pipeline/kfp/test_processor_kfp.py

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions elyra/tests/pipeline/resources/components/download_data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
#
name: Download data
inputs:
- {name: Url, type: URI}
- {name: curl options, type: string, default: '--location', description: 'Additional options given to the curl program. See https://curl.haxx.se/docs/manpage.html'}
- {name: Url, type: String}
- {name: curl options, type: String, default: '--location', description: 'Additional options given to the curl program. See https://curl.haxx.se/docs/manpage.html'}
outputs:
- {name: Data}
metadata:
Expand Down
2 changes: 1 addition & 1 deletion elyra/tests/util/test_kubernetes.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def test_is_valid_label_key_valid_input():
assert is_valid_label_key(key="p/n")
assert is_valid_label_key(key="prefix/you.2")
assert is_valid_label_key(key="how.sad/to-see")
assert is_valid_label_key(key=f"{'d' * 253} / {'n' * 63}")
assert is_valid_label_key(key=f"{'d' * 253}/{'n' * 63}")


def test_is_valid_label_value_invalid_input():
Expand Down
1 change: 0 additions & 1 deletion test_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,3 @@ pytest-tornasync
pytest_virtualenv
requests-mock
requests-unixsocket
kfp-tekton
9 changes: 6 additions & 3 deletions tests/integration/01-scriptdebugger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,12 @@ describe('Script debugger tests', () => {
'test for debugger button disabled for default kernel without debug support',
{ defaultCommandTimeout: TIMEOUT },
() => {
cy.createNewScriptEditor('R');
cy.createNewScriptEditor('Python');
cy.get(
'.elyra-ScriptEditor .jp-Toolbar select > option[value*=python]'
).should('not.exist');
checkDebuggerButtonEnabled(false);
cy.deleteFile('untitled.r');
cy.deleteFile('untitled.py');
}
);
});
Expand All @@ -102,6 +102,9 @@ const checkDebuggerButtonEnabled = (enabled: boolean): void => {
const openFile = (fileName: string): void => {
cy.findByRole('menuitem', { name: /file/i }).click();
cy.findByText(/^open from path$/i).click({ force: true });
cy.get('input#jp-dialog-input-id').type(`/${fileName}`);
cy.get('input#jp-dialog-input-id')
.clear()
.type(`/${fileName}`)
.should('have.value', `/${fileName}`);
cy.get('.p-Panel .jp-mod-accept').click();
};
3 changes: 0 additions & 3 deletions tests/integration/launcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,6 @@ describe('Elyra launcher is in use', () => {
cy.get(
'.jp-LauncherCard[data-category="Elyra"][title="Create a new Python Editor"]:visible'
);
cy.get(
'.jp-LauncherCard[data-category="Elyra"][title="Create a new R Editor"]:visible'
);
// Documentation link is available
cy.get(
'.jp-LauncherCard[data-category="Elyra"][title="Documentation"]:visible'
Expand Down
77 changes: 0 additions & 77 deletions tests/integration/reditor.ts

This file was deleted.

2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3339,7 +3339,7 @@
dependencies:
"@lumino/algorithm" "^1.9.2"

"@lumino/widgets@^1.19.0", "@lumino/widgets@^1.30.1", "@lumino/widgets@^1.31.1", "@lumino/widgets@^1.33.0", "@lumino/widgets@^1.34.0":
"@lumino/widgets@^1.19.0", "@lumino/widgets@^1.30.1", "@lumino/widgets@^1.33.0", "@lumino/widgets@^1.34.0":
version "1.34.0"
resolved "https://registry.yarnpkg.com/@lumino/widgets/-/widgets-1.34.0.tgz#0cc9ae568b7c129247e240d9b277ead324d4352f"
integrity sha512-HvvZ/UL1mcbvZ2IZrIA5p+YVSjTzQYrkXwPkFDPs6TgSgj5VmBm8Y13B7gS+/p9634OR5WNiWVO3KNALVHRXcw==
Expand Down

0 comments on commit 196f35c

Please sign in to comment.