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

[tests-only] Run web UI ocisSmokeTest scenarios in a single pipeline #2093

Merged
merged 1 commit into from
May 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
84 changes: 36 additions & 48 deletions .drone.star
Original file line number Diff line number Diff line change
Expand Up @@ -28,82 +28,63 @@ config = {
},
"uiTests": {
"suites": {
"webUIBasic": [
"webUISmokeTest": [
"webUILogin",
"webUINotifications",
"webUIPrivateLinks",
"webUIPreview",
"webUIAccount",
# The following suites may have all scenarios currently skipped.
# The suites are listed here so that scenarios will run when
# they are enabled.
"webUIAdminSettings",
"webUIComments",
"webUITags",
"webUIWebdavLockProtection",
"webUIWebdavLocks",
],
"webUICreateFilesFolders": "webUICreateFilesFolders",
"webUIDeleteFilesFolders": "webUIDeleteFilesFolders",
"webUIRename": [
"webUICreateFilesFolders",
"webUIDeleteFilesFolders",
"webUIRenameFiles",
"webUIRenameFolders",
],
"webUISharingBasic": [
"webUISharingAcceptShares",
],
"webUIRestrictSharing": "webUIRestrictSharing",
"webUISharingNotifications": [
"webUIRestrictSharing",
"webUISharingNotifications",
],
"webUIFavorites": "webUIFavorites",
"webUIMarkdownEditor": "webUIMarkdownEditor",
"webUIFiles1": [
"webUIFavorites",
"webUIMarkdownEditor",
"webUIFiles",
"webUIFilesActionMenu",
"webUIFilesCopy",
],
"webUIFiles2": [
"webUIFilesDetails",
"webUIFilesList",
"webUIFilesSearch",
],
"webUISharingAutocompletion": "webUISharingAutocompletion",
"webUISharingInternalGroups": [
"webUISharingAutocompletion",
"webUISharingInternalGroups",
"webUISharingInternalGroupsEdgeCases",
"webUISharingInternalGroupsSharingIndicator",
],
"webUISharingInternalUsers": [
"webUISharingInternalUsers",
"webUISharingInternalUsersBlacklisted",
"webUISharingInternalUsersSharingIndicator",
"webUISharingInternalUsersCollaborator",
"webUISharingInternalUsersShareWithPage",
],
"webUISharingInternalUsersExpire": "webUISharingInternalUsersExpire",
"webUISharingPermissionsUsers": "webUISharingPermissionsUsers",
"webUISharingFilePermissionsGroups": "webUISharingFilePermissionsGroups",
"webUISharingFolderPermissionsGroups": "webUISharingFolderPermissionsGroups",
"webUISharingFolderAdvPermissionsGrp": "webUISharingFolderAdvancedPermissionsGroups",
"webUIResharing": [
"webUISharingInternalUsersExpire",
"webUISharingPermissionsUsers",
"webUISharingFilePermissionsGroups",
"webUISharingFolderPermissionsGroups",
"webUISharingFolderAdvancedPermissionsGroups",
"webUIResharing1",
"webUIResharing2",
"webUISharingPublicBasic",
"webUISharingPublicManagement",
"webUISharingPublicExpire",
"webUISharingPublicDifferentRoles",
"webUITrashbinDelete",
"webUITrashbinFilesFolders",
"webUITrashbinRestore",
"webUIUpload",
"webUISharingFilePermissionMultipleUsers",
"webUISharingFolderPermissionMultipleUsers",
"webUISharingFolderAdvancedPermissionMultipleUsers",
"webUIMoveFilesFolders",
"webUIUserJourney",
],
"webUISharingPublicBasic": "webUISharingPublicBasic",
"webUISharingPublicManagement": "webUISharingPublicManagement",
"webUISharingPublicExpire": "webUISharingPublicExpire",
"webUISharingPublicDifferentRoles": "webUISharingPublicDifferentRoles",
"webUITrashbinDelete": "webUITrashbinDelete",
"webUITrashbinFilesFolders": "webUITrashbinFilesFolders",
"webUITrashbinRestore": "webUITrashbinRestore",
"webUIUpload": "webUIUpload",
"webUISharingFilePermissionMultipleUsers": "webUISharingFilePermissionMultipleUsers",
"webUISharingFolderPermissionMultipleUsers": "webUISharingFolderPermissionMultipleUsers",
"webUISharingFolderAdvancedPermissionMU": "webUISharingFolderAdvancedPermissionMultipleUsers",
"webUIMoveFilesFolders": "webUIMoveFilesFolders",
"webUIUserJourney": "webUIUserJourney",
},
"filterTags": "@ocisSmokeTest",
"debugSuites": [],
"skip": False,
},
Expand Down Expand Up @@ -562,6 +543,7 @@ def apiTests(ctx):

def uiTests(ctx):
default = {
"filterTags": "",
"debugSuites": [],
"skip": False,
}
Expand All @@ -575,9 +557,9 @@ def uiTests(ctx):
if len(params["debugSuites"]) != 0:
suiteNames = params["debugSuites"]

return [uiTestPipeline(ctx, suiteName) for suiteName in suiteNames]
return [uiTestPipeline(ctx, suiteName, params["filterTags"]) for suiteName in suiteNames]

def uiTestPipeline(ctx, suiteName, storage = "ocis", accounts_hash_difficulty = 4):
def uiTestPipeline(ctx, suiteName, filterTags, storage = "ocis", accounts_hash_difficulty = 4):
suites = config["uiTests"]["suites"]
paths = ""
suite = suites[suiteName]
Expand All @@ -587,6 +569,12 @@ def uiTestPipeline(ctx, suiteName, storage = "ocis", accounts_hash_difficulty =
else:
paths = paths + "tests/acceptance/features/" + suite + " "

standardFilterTags = "not @skipOnOCIS and not @skip and not @notToImplementOnOCIS"
if filterTags == "":
finalFilterTags = standardFilterTags
else:
finalFilterTags = filterTags + " and " + standardFilterTags

return {
"kind": "pipeline",
"type": "docker",
Expand All @@ -608,7 +596,7 @@ def uiTestPipeline(ctx, suiteName, storage = "ocis", accounts_hash_difficulty =
"OCIS_REVA_DATA_ROOT": "/srv/app/tmp/ocis/owncloud/data",
"TESTING_DATA_DIR": "/srv/app/testing/data",
"WEB_UI_CONFIG": "/drone/src/tests/config/drone/ocis-config.json",
"TEST_TAGS": "not @skipOnOCIS and not @skip and not @notToImplementOnOCIS",
"TEST_TAGS": finalFilterTags,
"LOCAL_UPLOAD_DIR": "/uploads",
"NODE_TLS_REJECT_UNAUTHORIZED": 0,
"TEST_PATHS": paths,
Expand Down
Loading