@azure/playwright 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/dist/browser/common/constants.d.ts +1 -4
  2. package/dist/browser/common/constants.d.ts.map +1 -1
  3. package/dist/browser/common/constants.js +1 -4
  4. package/dist/browser/common/constants.js.map +1 -1
  5. package/dist/browser/common/types.d.ts +0 -4
  6. package/dist/browser/common/types.d.ts.map +1 -1
  7. package/dist/browser/common/types.js.map +1 -1
  8. package/dist/browser/reporter/playwrightReporter.d.ts +0 -1
  9. package/dist/browser/reporter/playwrightReporter.d.ts.map +1 -1
  10. package/dist/browser/reporter/playwrightReporter.js +3 -17
  11. package/dist/browser/reporter/playwrightReporter.js.map +1 -1
  12. package/dist/browser/utils/PlaywrightServiceClient.d.ts +1 -2
  13. package/dist/browser/utils/PlaywrightServiceClient.d.ts.map +1 -1
  14. package/dist/browser/utils/PlaywrightServiceClient.js +1 -26
  15. package/dist/browser/utils/PlaywrightServiceClient.js.map +1 -1
  16. package/dist/browser/utils/utils.d.ts +2 -3
  17. package/dist/browser/utils/utils.d.ts.map +1 -1
  18. package/dist/browser/utils/utils.js +8 -21
  19. package/dist/browser/utils/utils.js.map +1 -1
  20. package/dist/commonjs/common/constants.d.ts +1 -4
  21. package/dist/commonjs/common/constants.d.ts.map +1 -1
  22. package/dist/commonjs/common/constants.js +2 -5
  23. package/dist/commonjs/common/constants.js.map +1 -1
  24. package/dist/commonjs/common/types.d.ts +0 -4
  25. package/dist/commonjs/common/types.d.ts.map +1 -1
  26. package/dist/commonjs/common/types.js.map +1 -1
  27. package/dist/commonjs/reporter/playwrightReporter.d.ts +0 -1
  28. package/dist/commonjs/reporter/playwrightReporter.d.ts.map +1 -1
  29. package/dist/commonjs/reporter/playwrightReporter.js +2 -16
  30. package/dist/commonjs/reporter/playwrightReporter.js.map +1 -1
  31. package/dist/commonjs/tsdoc-metadata.json +1 -1
  32. package/dist/commonjs/utils/PlaywrightServiceClient.d.ts +1 -2
  33. package/dist/commonjs/utils/PlaywrightServiceClient.d.ts.map +1 -1
  34. package/dist/commonjs/utils/PlaywrightServiceClient.js +0 -25
  35. package/dist/commonjs/utils/PlaywrightServiceClient.js.map +1 -1
  36. package/dist/commonjs/utils/utils.d.ts +2 -3
  37. package/dist/commonjs/utils/utils.d.ts.map +1 -1
  38. package/dist/commonjs/utils/utils.js +8 -22
  39. package/dist/commonjs/utils/utils.js.map +1 -1
  40. package/dist/esm/common/constants.d.ts +1 -4
  41. package/dist/esm/common/constants.d.ts.map +1 -1
  42. package/dist/esm/common/constants.js +92 -96
  43. package/dist/esm/common/constants.js.map +1 -7
  44. package/dist/esm/common/customerConfig.js +11 -11
  45. package/dist/esm/common/customerConfig.js.map +1 -7
  46. package/dist/esm/common/entraIdAccessToken.js +77 -85
  47. package/dist/esm/common/entraIdAccessToken.js.map +1 -7
  48. package/dist/esm/common/environmentVariables.js +19 -19
  49. package/dist/esm/common/environmentVariables.js.map +1 -7
  50. package/dist/esm/common/executor.js +58 -51
  51. package/dist/esm/common/executor.js.map +1 -7
  52. package/dist/esm/common/httpService.js +29 -34
  53. package/dist/esm/common/httpService.js.map +1 -7
  54. package/dist/esm/common/logger.js +4 -4
  55. package/dist/esm/common/logger.js.map +1 -7
  56. package/dist/esm/common/messages.js +166 -166
  57. package/dist/esm/common/messages.js.map +1 -7
  58. package/dist/esm/common/playwrightServiceConfig.js +91 -91
  59. package/dist/esm/common/playwrightServiceConfig.js.map +1 -7
  60. package/dist/esm/common/state.js +7 -7
  61. package/dist/esm/common/state.js.map +1 -7
  62. package/dist/esm/common/types.d.ts +0 -4
  63. package/dist/esm/common/types.d.ts.map +1 -1
  64. package/dist/esm/common/types.js +4 -0
  65. package/dist/esm/common/types.js.map +1 -7
  66. package/dist/esm/core/global/playwright-service-global-setup.js +17 -17
  67. package/dist/esm/core/global/playwright-service-global-setup.js.map +1 -7
  68. package/dist/esm/core/global/playwright-service-global-teardown.js +13 -16
  69. package/dist/esm/core/global/playwright-service-global-teardown.js.map +1 -7
  70. package/dist/esm/core/initializePlaywrightServiceTestRun.js +21 -13
  71. package/dist/esm/core/initializePlaywrightServiceTestRun.js.map +1 -7
  72. package/dist/esm/core/playwrightService.js +200 -149
  73. package/dist/esm/core/playwrightService.js.map +1 -7
  74. package/dist/esm/core/playwrightServiceEntra.js +42 -44
  75. package/dist/esm/core/playwrightServiceEntra.js.map +1 -7
  76. package/dist/esm/core/playwrightServiceUtils.js +8 -6
  77. package/dist/esm/core/playwrightServiceUtils.js.map +1 -7
  78. package/dist/esm/index.js +9 -7
  79. package/dist/esm/index.js.map +1 -7
  80. package/dist/esm/reporter/index.js +11 -4
  81. package/dist/esm/reporter/index.js.map +1 -7
  82. package/dist/esm/reporter/playwrightReporter.d.ts +0 -1
  83. package/dist/esm/reporter/playwrightReporter.d.ts.map +1 -1
  84. package/dist/esm/reporter/playwrightReporter.js +193 -202
  85. package/dist/esm/reporter/playwrightReporter.js.map +1 -7
  86. package/dist/esm/utils/PlaywrightServiceClient.d.ts +1 -2
  87. package/dist/esm/utils/PlaywrightServiceClient.d.ts.map +1 -1
  88. package/dist/esm/utils/PlaywrightServiceClient.js +61 -121
  89. package/dist/esm/utils/PlaywrightServiceClient.js.map +1 -7
  90. package/dist/esm/utils/cIInfoProvider.js +71 -58
  91. package/dist/esm/utils/cIInfoProvider.js.map +1 -7
  92. package/dist/esm/utils/getPackageVersion.js +17 -12
  93. package/dist/esm/utils/getPackageVersion.js.map +1 -7
  94. package/dist/esm/utils/getPlaywrightVersion.js +13 -15
  95. package/dist/esm/utils/getPlaywrightVersion.js.map +1 -7
  96. package/dist/esm/utils/packageManager.js +37 -37
  97. package/dist/esm/utils/packageManager.js.map +1 -7
  98. package/dist/esm/utils/parseJwt.js +14 -15
  99. package/dist/esm/utils/parseJwt.js.map +1 -7
  100. package/dist/esm/utils/playwrightReporterStorageManager.js +333 -358
  101. package/dist/esm/utils/playwrightReporterStorageManager.js.map +1 -7
  102. package/dist/esm/utils/utils.d.ts +2 -3
  103. package/dist/esm/utils/utils.d.ts.map +1 -1
  104. package/dist/esm/utils/utils.js +338 -380
  105. package/dist/esm/utils/utils.js.map +1 -7
  106. package/dist/react-native/common/constants.d.ts +1 -4
  107. package/dist/react-native/common/constants.d.ts.map +1 -1
  108. package/dist/react-native/common/constants.js +1 -4
  109. package/dist/react-native/common/constants.js.map +1 -1
  110. package/dist/react-native/common/types.d.ts +0 -4
  111. package/dist/react-native/common/types.d.ts.map +1 -1
  112. package/dist/react-native/common/types.js.map +1 -1
  113. package/dist/react-native/reporter/playwrightReporter.d.ts +0 -1
  114. package/dist/react-native/reporter/playwrightReporter.d.ts.map +1 -1
  115. package/dist/react-native/reporter/playwrightReporter.js +3 -17
  116. package/dist/react-native/reporter/playwrightReporter.js.map +1 -1
  117. package/dist/react-native/utils/PlaywrightServiceClient.d.ts +1 -2
  118. package/dist/react-native/utils/PlaywrightServiceClient.d.ts.map +1 -1
  119. package/dist/react-native/utils/PlaywrightServiceClient.js +1 -26
  120. package/dist/react-native/utils/PlaywrightServiceClient.js.map +1 -1
  121. package/dist/react-native/utils/utils.d.ts +2 -3
  122. package/dist/react-native/utils/utils.d.ts.map +1 -1
  123. package/dist/react-native/utils/utils.js +8 -21
  124. package/dist/react-native/utils/utils.js.map +1 -1
  125. package/package.json +6 -6
@@ -1,167 +1,167 @@
1
- const ServiceErrorMessageConstants = {
2
- NO_SERVICE_URL_ERROR: {
3
- key: "NoServiceUrlError",
4
- message: "The value for the PLAYWRIGHT_SERVICE_URL variable is not set correctly. Please verify the URL and try again."
5
- },
6
- INVALID_GLOBAL_FUNCTION: {
7
- key: "InvalidGlobalFunction",
8
- message: "File must export a single function."
9
- },
10
- INVALID_PLAYWRIGHT_VERSION_ERROR: {
11
- key: "InvalidPlaywrightVersionError",
12
- message: "The Playwright version you are using is not supported. See the list of supported versions at https://aka.ms/pww/docs/supported-versions."
13
- },
14
- PLAYWRIGHT_VERSION_TOO_OLD_FOR_REPORTING: {
15
- key: "PlaywrightVersionTooOldForReporting",
16
- message: "To use the Playwright Workspaces reporting feature, you need Playwright version 1.57 or later installed. Update the Playwright package to a supported version and try again."
17
- },
18
- MULTIPLE_SETUP_FILE_PLAYWRIGHT_VERSION_ERROR: {
19
- key: "MultipleSetupFilePlaywrightVersionError",
20
- message: "The Playwright version you are using does not support multiple setup/teardown files. Please update to Playwright version 1.49.0 or higher."
21
- },
22
- WORKSPACE_MISMATCH_ERROR: {
23
- key: "InvalidAccessToken",
24
- message: "The provided access token does not match the specified workspace URL. Please verify that both values are correct."
25
- },
26
- NO_AUTH_ERROR_PAT_TOKEN: {
27
- key: "NoAuthErrorPatToken",
28
- message: "Please set PLAYWRIGHT_SERVICE_ACCESS_TOKEN env variable when using ACCESS_TOKEN authentication. For more information, see https://aka.ms/pww/docs/authentication"
29
- },
30
- NO_AUTH_ERROR_ENTRA_TOKEN: {
31
- key: "NoAuthErrorEntraToken",
32
- message: "Could not authenticate with the service. For more information, see https://aka.ms/pww/docs/authentication"
33
- },
34
- INVALID_MPT_PAT_ERROR: {
35
- key: "InvalidMptPatError",
36
- message: "The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided is invalid. Please make sure to set a valid token."
37
- },
38
- EXPIRED_MPT_PAT_ERROR: {
39
- key: "ExpiredMptPatError",
40
- message: "The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided has expired. Create a new token."
41
- },
42
- NO_CRED_ENTRA_AUTH_ERROR: {
43
- key: "NoCredEntraAuthError",
44
- message: "Missing 'credential' parameter which is required when using ENTRA_ID authentication, Azure credential not provided. See https://aka.ms/pww/docs/authentication for more information."
45
- },
46
- FAILED_TO_CREATE_TEST_RUN: {
47
- key: "FailedToCreateTestRun",
48
- message: "Failed to create the test run in the Playwright workspaces. For more information, see https://aka.ms/pww/docs/troubleshooting",
49
- formatWithErrorDetails: (errorDetails) => `Failed to create the test run in the Playwright workspaces. Error: ${errorDetails}. For more information, see https://aka.ms/pww/docs/troubleshooting`
50
- },
51
- INVALID_PARAM_WITH_SERVICE_CONFIG: {
52
- key: "InvalidParamWithServiceConfig",
53
- message: `Remove serviceAuth, runId, and runName from getConnectOptions when using createAzurePlaywrightConfig. Configure these options through createAzurePlaywrightConfig instead.`
54
- },
55
- INVALID_RUN_ID_FORMAT: {
56
- key: "InvalidRunIdFormat",
57
- message: "The Run ID must be a valid GUID format. Please provide a valid GUID for the Run ID."
58
- },
59
- INVALID_AUTH_TYPE_ERROR: {
60
- key: "InvalidAuthTypeError",
61
- message: "Invalid authentication type specified. Please use either ENTRA_ID or ACCESS_TOKEN."
62
- },
63
- FAILED_TO_GET_WORKSPACE_DETAILS: {
64
- key: "FailedToGetWorkspaceDetails",
65
- message: "Failed to retrieve workspace details from the Playwright service.",
66
- formatWithErrorDetails: (errorDetails) => `Failed to retrieve workspace details from the Playwright service. Error: ${errorDetails}. Please verify your service URL and authentication credentials.`
67
- },
68
- STORAGE_URI_NOT_FOUND: {
69
- key: "StorageUriNotFound",
70
- message: "Storage Account is not linked with this Playwright Workspace."
71
- },
72
- STORAGE_AUTHORIZATION_FAILED: {
73
- key: "StorageAuthorizationFailed",
74
- message: "The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account. For more information, see https://aka.ms/pww-reporting",
75
- formatWithStorageAccount: (storageAccountName) => `The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account - ${storageAccountName}. For more information, see https://aka.ms/pww-reporting`
76
- },
77
- UNABLE_TO_EXTRACT_WORKSPACE_ID: {
78
- key: "UnableToExtractWorkspaceId",
79
- message: "Unable to extract workspace ID from service URL"
80
- },
81
- STORAGE_ACCOUNT_DELETED: {
82
- key: "StorageAccountDeleted",
83
- message: "The storage account linked to your Playwright Workspace may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration",
84
- formatWithStorageAccount: (storageAccountName) => `The storage account linked to your Playwright Workspace (${storageAccountName}) may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration`
85
- },
86
- REPORTER_REQUIRES_ENTRA_AUTH: {
87
- key: "ReporterRequiresEntraAuth",
88
- message: "Playwright Workspaces Reporter can only be used with ENTRA_ID authentication. For more information, see https://aka.ms/pww/docs/authentication"
89
- },
90
- HTML_REPORTER_REQUIRED: {
91
- key: "HtmlReporterRequired",
92
- message: "Playwright Workspaces Reporter requires the 'html' reporter to be configured in your Playwright configuration. Please add the 'html' reporter before playwright workspace reporter to generate test reports that can be uploaded to Azure Storage. Example: reporter: [['html'], ['@azure/playwright/reporter']]. For more information, see https://aka.ms/pww-reporting"
93
- },
94
- WORKSPACE_METADATA_FETCH_FAILED: {
95
- key: "WorkspaceMetadataFetchFailed",
96
- message: "Failed to retrieve workspace configuration. Reporting will be disabled for this run. Please check your authentication credentials and service URL."
97
- },
98
- WORKSPACE_REPORTING_DISABLED: {
99
- key: "WorkspaceReportingDisabled",
100
- message: "Playwright Workspaces reporting: DISABLED. Reporting is not enabled for the Playwright Workspace. To learn more about how to enable reporting and link a storage account, see https://aka.ms/pww-reporting"
101
- },
102
- WORKSPACE_REPORTING_STORAGE_NOT_LINKED: {
103
- key: "WorkspaceReportingStorageNotLinked",
104
- message: "Playwright Workspaces reporting: DISABLED. Reporting is enabled for the Playwright Workspace, but no storage account is linked. Please link a storage account to enable reporting. For more information, see https://aka.ms/pww-reporting"
105
- },
106
- UPLOAD_FAILED_FILES: {
107
- key: "UploadFailedFiles",
108
- message: "Upload failed: files could not be uploaded",
109
- formatWithCount: (failed) => `Upload failed: ${failed} files could not be uploaded`
110
- },
111
- PLAYWRIGHT_TEST_REPORT_NOT_FOUND: {
112
- key: "PlaywrightTestReportNotFound",
113
- message: "Playwright test report not found",
114
- formatWithFolder: (folderName) => `Playwright test report not found: ${folderName}. For more information, see https://aka.ms/pww-reporting`
115
- },
116
- REPORTING_ENABLED: {
117
- key: "ReportingEnabled",
118
- message: "Playwright Workspaces reporting: ENABLED"
119
- },
120
- COLLECTING_ARTIFACTS: {
121
- key: "CollectingArtifacts",
122
- message: "Collecting artifacts: screenshots, videos, traces."
123
- },
124
- REPORTING_STATUS_SUCCESS: {
125
- key: "ReportingStatusSuccess",
126
- message: "Reporting upload status: SUCCESS"
127
- },
128
- REPORTING_STATUS_PARTIAL: {
129
- key: "ReportingStatusPartial",
130
- message: "Reporting upload status: Partially Uploaded"
131
- },
132
- REPORTING_STATUS_FAILED: {
133
- key: "ReportingStatusFailed",
134
- message: "Reporting upload status: FAILED"
135
- },
136
- TEST_REPORT_VIEW_URL: {
137
- key: "TestReportViewUrl",
138
- message: "Published report URL: ",
139
- formatWithUrl: (url) => `Published report URL: ${url}`
140
- },
141
- UPLOADING_ARTIFACTS: {
142
- key: "UploadingArtifacts",
143
- message: "Uploading artifacts to storage",
144
- formatWithDetails: (storageAccount, container, folder) => `Uploading artifacts to: storage account= ${storageAccount}, storage container= ${container}, folder= ${folder}`
145
- },
146
- FAILED_TO_GET_WORKSPACE_METADATA: {
147
- key: "FailedToGetWorkspaceMetadata",
148
- message: "Failed to get workspace metadata",
149
- formatWithError: (error) => error
150
- },
151
- TEST_RUN_CREATION_FAILED: {
152
- key: "TestRunCreationFailed",
153
- message: "Failed to create test run. Test execution will continue.",
154
- formatWithErrorDetails: (errorDetails) => `Failed to create test run. Error: ${errorDetails}. Test execution will continue.`
155
- },
156
- REPORTING_TEST_RUN_FAILED: {
157
- key: "ReportingTestRunFailed",
158
- message: "Test run creation failed during setup."
159
- },
160
- REPORTER_REQUIRES_SERVICE_CONFIG: {
161
- key: "ReporterRequiresServiceConfig",
162
- message: "Playwright Workspaces Reporter requires the use of service configuration via createAzurePlaywrightConfig. For more information, see https://aka.ms/pww-reporting."
163
- }
164
- };
165
- export {
166
- ServiceErrorMessageConstants
1
+ // Copyright (c) Microsoft Corporation.
2
+ // Licensed under the MIT License.
3
+ export const ServiceErrorMessageConstants = {
4
+ NO_SERVICE_URL_ERROR: {
5
+ key: "NoServiceUrlError",
6
+ message: "The value for the PLAYWRIGHT_SERVICE_URL variable is not set correctly. Please verify the URL and try again.",
7
+ },
8
+ INVALID_GLOBAL_FUNCTION: {
9
+ key: "InvalidGlobalFunction",
10
+ message: "File must export a single function.",
11
+ },
12
+ INVALID_PLAYWRIGHT_VERSION_ERROR: {
13
+ key: "InvalidPlaywrightVersionError",
14
+ message: "The Playwright version you are using is not supported. See the list of supported versions at https://aka.ms/pww/docs/supported-versions.",
15
+ },
16
+ PLAYWRIGHT_VERSION_TOO_OLD_FOR_REPORTING: {
17
+ key: "PlaywrightVersionTooOldForReporting",
18
+ message: "To use the Playwright Workspaces reporting feature, you need Playwright version 1.57 or later installed. Update the Playwright package to a supported version and try again.",
19
+ },
20
+ MULTIPLE_SETUP_FILE_PLAYWRIGHT_VERSION_ERROR: {
21
+ key: "MultipleSetupFilePlaywrightVersionError",
22
+ message: "The Playwright version you are using does not support multiple setup/teardown files. Please update to Playwright version 1.49.0 or higher.",
23
+ },
24
+ WORKSPACE_MISMATCH_ERROR: {
25
+ key: "InvalidAccessToken",
26
+ message: "The provided access token does not match the specified workspace URL. Please verify that both values are correct.",
27
+ },
28
+ NO_AUTH_ERROR_PAT_TOKEN: {
29
+ key: "NoAuthErrorPatToken",
30
+ message: "Please set PLAYWRIGHT_SERVICE_ACCESS_TOKEN env variable when using ACCESS_TOKEN authentication. For more information, see https://aka.ms/pww/docs/authentication",
31
+ },
32
+ NO_AUTH_ERROR_ENTRA_TOKEN: {
33
+ key: "NoAuthErrorEntraToken",
34
+ message: "Could not authenticate with the service. For more information, see https://aka.ms/pww/docs/authentication",
35
+ },
36
+ INVALID_MPT_PAT_ERROR: {
37
+ key: "InvalidMptPatError",
38
+ message: "The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided is invalid. Please make sure to set a valid token.",
39
+ },
40
+ EXPIRED_MPT_PAT_ERROR: {
41
+ key: "ExpiredMptPatError",
42
+ message: "The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided has expired. Create a new token.",
43
+ },
44
+ NO_CRED_ENTRA_AUTH_ERROR: {
45
+ key: "NoCredEntraAuthError",
46
+ message: "Missing 'credential' parameter which is required when using ENTRA_ID authentication, Azure credential not provided. See https://aka.ms/pww/docs/authentication for more information.",
47
+ },
48
+ FAILED_TO_CREATE_TEST_RUN: {
49
+ key: "FailedToCreateTestRun",
50
+ message: "Failed to create the test run in the Playwright workspaces. For more information, see https://aka.ms/pww/docs/troubleshooting",
51
+ formatWithErrorDetails: (errorDetails) => `Failed to create the test run in the Playwright workspaces. Error: ${errorDetails}. For more information, see https://aka.ms/pww/docs/troubleshooting`,
52
+ },
53
+ INVALID_PARAM_WITH_SERVICE_CONFIG: {
54
+ key: "InvalidParamWithServiceConfig",
55
+ message: `Remove serviceAuth, runId, and runName from getConnectOptions when using createAzurePlaywrightConfig. Configure these options through createAzurePlaywrightConfig instead.`,
56
+ },
57
+ INVALID_RUN_ID_FORMAT: {
58
+ key: "InvalidRunIdFormat",
59
+ message: "The Run ID must be a valid GUID format. Please provide a valid GUID for the Run ID.",
60
+ },
61
+ INVALID_AUTH_TYPE_ERROR: {
62
+ key: "InvalidAuthTypeError",
63
+ message: "Invalid authentication type specified. Please use either ENTRA_ID or ACCESS_TOKEN.",
64
+ },
65
+ FAILED_TO_GET_WORKSPACE_DETAILS: {
66
+ key: "FailedToGetWorkspaceDetails",
67
+ message: "Failed to retrieve workspace details from the Playwright service.",
68
+ formatWithErrorDetails: (errorDetails) => `Failed to retrieve workspace details from the Playwright service. Error: ${errorDetails}. Please verify your service URL and authentication credentials.`,
69
+ },
70
+ STORAGE_URI_NOT_FOUND: {
71
+ key: "StorageUriNotFound",
72
+ message: "Storage Account is not linked with this Playwright Workspace.",
73
+ },
74
+ STORAGE_AUTHORIZATION_FAILED: {
75
+ key: "StorageAuthorizationFailed",
76
+ message: "The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account. For more information, see https://aka.ms/pww-reporting",
77
+ formatWithStorageAccount: (storageAccountName) => `The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account - ${storageAccountName}. For more information, see https://aka.ms/pww-reporting`,
78
+ },
79
+ UNABLE_TO_EXTRACT_WORKSPACE_ID: {
80
+ key: "UnableToExtractWorkspaceId",
81
+ message: "Unable to extract workspace ID from service URL",
82
+ },
83
+ STORAGE_ACCOUNT_DELETED: {
84
+ key: "StorageAccountDeleted",
85
+ message: "The storage account linked to your Playwright Workspace may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration",
86
+ formatWithStorageAccount: (storageAccountName) => `The storage account linked to your Playwright Workspace (${storageAccountName}) may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration`,
87
+ },
88
+ REPORTER_REQUIRES_ENTRA_AUTH: {
89
+ key: "ReporterRequiresEntraAuth",
90
+ message: "Playwright Workspaces Reporter can only be used with ENTRA_ID authentication. For more information, see https://aka.ms/pww/docs/authentication",
91
+ },
92
+ HTML_REPORTER_REQUIRED: {
93
+ key: "HtmlReporterRequired",
94
+ message: "Playwright Workspaces Reporter requires the 'html' reporter to be configured in your Playwright configuration. Please add the 'html' reporter before playwright workspace reporter to generate test reports that can be uploaded to Azure Storage. Example: reporter: [['html'], ['@azure/playwright/reporter']]. For more information, see https://aka.ms/pww-reporting",
95
+ },
96
+ WORKSPACE_METADATA_FETCH_FAILED: {
97
+ key: "WorkspaceMetadataFetchFailed",
98
+ message: "Failed to retrieve workspace configuration. Reporting will be disabled for this run. Please check your authentication credentials and service URL.",
99
+ },
100
+ WORKSPACE_REPORTING_DISABLED: {
101
+ key: "WorkspaceReportingDisabled",
102
+ message: "Playwright Workspaces reporting: DISABLED. Reporting is not enabled for the Playwright Workspace. To learn more about how to enable reporting and link a storage account, see https://aka.ms/pww-reporting",
103
+ },
104
+ WORKSPACE_REPORTING_STORAGE_NOT_LINKED: {
105
+ key: "WorkspaceReportingStorageNotLinked",
106
+ message: "Playwright Workspaces reporting: DISABLED. Reporting is enabled for the Playwright Workspace, but no storage account is linked. Please link a storage account to enable reporting. For more information, see https://aka.ms/pww-reporting",
107
+ },
108
+ UPLOAD_FAILED_FILES: {
109
+ key: "UploadFailedFiles",
110
+ message: "Upload failed: files could not be uploaded",
111
+ formatWithCount: (failed) => `Upload failed: ${failed} files could not be uploaded`,
112
+ },
113
+ PLAYWRIGHT_TEST_REPORT_NOT_FOUND: {
114
+ key: "PlaywrightTestReportNotFound",
115
+ message: "Playwright test report not found",
116
+ formatWithFolder: (folderName) => `Playwright test report not found: ${folderName}. For more information, see https://aka.ms/pww-reporting`,
117
+ },
118
+ REPORTING_ENABLED: {
119
+ key: "ReportingEnabled",
120
+ message: "Playwright Workspaces reporting: ENABLED",
121
+ },
122
+ COLLECTING_ARTIFACTS: {
123
+ key: "CollectingArtifacts",
124
+ message: "Collecting artifacts: screenshots, videos, traces.",
125
+ },
126
+ REPORTING_STATUS_SUCCESS: {
127
+ key: "ReportingStatusSuccess",
128
+ message: "Reporting upload status: SUCCESS",
129
+ },
130
+ REPORTING_STATUS_PARTIAL: {
131
+ key: "ReportingStatusPartial",
132
+ message: "Reporting upload status: Partially Uploaded",
133
+ },
134
+ REPORTING_STATUS_FAILED: {
135
+ key: "ReportingStatusFailed",
136
+ message: "Reporting upload status: FAILED",
137
+ },
138
+ TEST_REPORT_VIEW_URL: {
139
+ key: "TestReportViewUrl",
140
+ message: "Published report URL: ",
141
+ formatWithUrl: (url) => `Published report URL: ${url}`,
142
+ },
143
+ UPLOADING_ARTIFACTS: {
144
+ key: "UploadingArtifacts",
145
+ message: "Uploading artifacts to storage",
146
+ formatWithDetails: (storageAccount, container, folder) => `Uploading artifacts to: storage account= ${storageAccount}, storage container= ${container}, folder= ${folder}`,
147
+ },
148
+ FAILED_TO_GET_WORKSPACE_METADATA: {
149
+ key: "FailedToGetWorkspaceMetadata",
150
+ message: "Failed to get workspace metadata",
151
+ formatWithError: (error) => error,
152
+ },
153
+ TEST_RUN_CREATION_FAILED: {
154
+ key: "TestRunCreationFailed",
155
+ message: "Failed to create test run. Test execution will continue.",
156
+ formatWithErrorDetails: (errorDetails) => `Failed to create test run. Error: ${errorDetails}. Test execution will continue.`,
157
+ },
158
+ REPORTING_TEST_RUN_FAILED: {
159
+ key: "ReportingTestRunFailed",
160
+ message: "Test run creation failed during setup.",
161
+ },
162
+ REPORTER_REQUIRES_SERVICE_CONFIG: {
163
+ key: "ReporterRequiresServiceConfig",
164
+ message: "Playwright Workspaces Reporter requires the use of service configuration via createAzurePlaywrightConfig. For more information, see https://aka.ms/pww-reporting.",
165
+ },
167
166
  };
167
+ //# sourceMappingURL=messages.js.map
@@ -1,7 +1 @@
1
- {
2
- "version": 3,
3
- "sources": ["/mnt/vss/_work/1/s/sdk/loadtesting/playwright/src/common/messages.ts"],
4
- "sourcesContent": ["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const ServiceErrorMessageConstants = {\n NO_SERVICE_URL_ERROR: {\n key: \"NoServiceUrlError\",\n message:\n \"The value for the PLAYWRIGHT_SERVICE_URL variable is not set correctly. Please verify the URL and try again.\",\n },\n INVALID_GLOBAL_FUNCTION: {\n key: \"InvalidGlobalFunction\",\n message: \"File must export a single function.\",\n },\n INVALID_PLAYWRIGHT_VERSION_ERROR: {\n key: \"InvalidPlaywrightVersionError\",\n message:\n \"The Playwright version you are using is not supported. See the list of supported versions at https://aka.ms/pww/docs/supported-versions.\",\n },\n PLAYWRIGHT_VERSION_TOO_OLD_FOR_REPORTING: {\n key: \"PlaywrightVersionTooOldForReporting\",\n message:\n \"To use the Playwright Workspaces reporting feature, you need Playwright version 1.57 or later installed. Update the Playwright package to a supported version and try again.\",\n },\n MULTIPLE_SETUP_FILE_PLAYWRIGHT_VERSION_ERROR: {\n key: \"MultipleSetupFilePlaywrightVersionError\",\n message:\n \"The Playwright version you are using does not support multiple setup/teardown files. Please update to Playwright version 1.49.0 or higher.\",\n },\n WORKSPACE_MISMATCH_ERROR: {\n key: \"InvalidAccessToken\",\n message:\n \"The provided access token does not match the specified workspace URL. Please verify that both values are correct.\",\n },\n NO_AUTH_ERROR_PAT_TOKEN: {\n key: \"NoAuthErrorPatToken\",\n message:\n \"Please set PLAYWRIGHT_SERVICE_ACCESS_TOKEN env variable when using ACCESS_TOKEN authentication. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n NO_AUTH_ERROR_ENTRA_TOKEN: {\n key: \"NoAuthErrorEntraToken\",\n message:\n \"Could not authenticate with the service. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n INVALID_MPT_PAT_ERROR: {\n key: \"InvalidMptPatError\",\n message:\n \"The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided is invalid. Please make sure to set a valid token.\",\n },\n EXPIRED_MPT_PAT_ERROR: {\n key: \"ExpiredMptPatError\",\n message: \"The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided has expired. Create a new token.\",\n },\n NO_CRED_ENTRA_AUTH_ERROR: {\n key: \"NoCredEntraAuthError\",\n message:\n \"Missing 'credential' parameter which is required when using ENTRA_ID authentication, Azure credential not provided. See https://aka.ms/pww/docs/authentication for more information.\",\n },\n FAILED_TO_CREATE_TEST_RUN: {\n key: \"FailedToCreateTestRun\",\n message:\n \"Failed to create the test run in the Playwright workspaces. For more information, see https://aka.ms/pww/docs/troubleshooting\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to create the test run in the Playwright workspaces. Error: ${errorDetails}. For more information, see https://aka.ms/pww/docs/troubleshooting`,\n },\n INVALID_PARAM_WITH_SERVICE_CONFIG: {\n key: \"InvalidParamWithServiceConfig\",\n message: `Remove serviceAuth, runId, and runName from getConnectOptions when using createAzurePlaywrightConfig. Configure these options through createAzurePlaywrightConfig instead.`,\n },\n INVALID_RUN_ID_FORMAT: {\n key: \"InvalidRunIdFormat\",\n message: \"The Run ID must be a valid GUID format. Please provide a valid GUID for the Run ID.\",\n },\n INVALID_AUTH_TYPE_ERROR: {\n key: \"InvalidAuthTypeError\",\n message: \"Invalid authentication type specified. Please use either ENTRA_ID or ACCESS_TOKEN.\",\n },\n FAILED_TO_GET_WORKSPACE_DETAILS: {\n key: \"FailedToGetWorkspaceDetails\",\n message: \"Failed to retrieve workspace details from the Playwright service.\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to retrieve workspace details from the Playwright service. Error: ${errorDetails}. Please verify your service URL and authentication credentials.`,\n },\n STORAGE_URI_NOT_FOUND: {\n key: \"StorageUriNotFound\",\n message: \"Storage Account is not linked with this Playwright Workspace.\",\n },\n STORAGE_AUTHORIZATION_FAILED: {\n key: \"StorageAuthorizationFailed\",\n message:\n \"The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account. For more information, see https://aka.ms/pww-reporting\",\n formatWithStorageAccount: (storageAccountName: string): string =>\n `The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account - ${storageAccountName}. For more information, see https://aka.ms/pww-reporting`,\n },\n UNABLE_TO_EXTRACT_WORKSPACE_ID: {\n key: \"UnableToExtractWorkspaceId\",\n message: \"Unable to extract workspace ID from service URL\",\n },\n STORAGE_ACCOUNT_DELETED: {\n key: \"StorageAccountDeleted\",\n message:\n \"The storage account linked to your Playwright Workspace may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration\",\n formatWithStorageAccount: (storageAccountName: string): string =>\n `The storage account linked to your Playwright Workspace (${storageAccountName}) may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration`,\n },\n REPORTER_REQUIRES_ENTRA_AUTH: {\n key: \"ReporterRequiresEntraAuth\",\n message:\n \"Playwright Workspaces Reporter can only be used with ENTRA_ID authentication. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n HTML_REPORTER_REQUIRED: {\n key: \"HtmlReporterRequired\",\n message:\n \"Playwright Workspaces Reporter requires the 'html' reporter to be configured in your Playwright configuration. Please add the 'html' reporter before playwright workspace reporter to generate test reports that can be uploaded to Azure Storage. Example: reporter: [['html'], ['@azure/playwright/reporter']]. For more information, see https://aka.ms/pww-reporting\",\n },\n WORKSPACE_METADATA_FETCH_FAILED: {\n key: \"WorkspaceMetadataFetchFailed\",\n message:\n \"Failed to retrieve workspace configuration. Reporting will be disabled for this run. Please check your authentication credentials and service URL.\",\n },\n WORKSPACE_REPORTING_DISABLED: {\n key: \"WorkspaceReportingDisabled\",\n message:\n \"Playwright Workspaces reporting: DISABLED. Reporting is not enabled for the Playwright Workspace. To learn more about how to enable reporting and link a storage account, see https://aka.ms/pww-reporting\",\n },\n WORKSPACE_REPORTING_STORAGE_NOT_LINKED: {\n key: \"WorkspaceReportingStorageNotLinked\",\n message:\n \"Playwright Workspaces reporting: DISABLED. Reporting is enabled for the Playwright Workspace, but no storage account is linked. Please link a storage account to enable reporting. For more information, see https://aka.ms/pww-reporting\",\n },\n UPLOAD_FAILED_FILES: {\n key: \"UploadFailedFiles\",\n message: \"Upload failed: files could not be uploaded\",\n formatWithCount: (failed: number): string =>\n `Upload failed: ${failed} files could not be uploaded`,\n },\n PLAYWRIGHT_TEST_REPORT_NOT_FOUND: {\n key: \"PlaywrightTestReportNotFound\",\n message: \"Playwright test report not found\",\n formatWithFolder: (folderName: string): string =>\n `Playwright test report not found: ${folderName}. For more information, see https://aka.ms/pww-reporting`,\n },\n REPORTING_ENABLED: {\n key: \"ReportingEnabled\",\n message: \"Playwright Workspaces reporting: ENABLED\",\n },\n COLLECTING_ARTIFACTS: {\n key: \"CollectingArtifacts\",\n message: \"Collecting artifacts: screenshots, videos, traces.\",\n },\n REPORTING_STATUS_SUCCESS: {\n key: \"ReportingStatusSuccess\",\n message: \"Reporting upload status: SUCCESS\",\n },\n REPORTING_STATUS_PARTIAL: {\n key: \"ReportingStatusPartial\",\n message: \"Reporting upload status: Partially Uploaded\",\n },\n REPORTING_STATUS_FAILED: {\n key: \"ReportingStatusFailed\",\n message: \"Reporting upload status: FAILED\",\n },\n TEST_REPORT_VIEW_URL: {\n key: \"TestReportViewUrl\",\n message: \"Published report URL: \",\n formatWithUrl: (url: string): string => `Published report URL: ${url}`,\n },\n UPLOADING_ARTIFACTS: {\n key: \"UploadingArtifacts\",\n message: \"Uploading artifacts to storage\",\n formatWithDetails: (storageAccount: string, container: string, folder: string): string =>\n `Uploading artifacts to: storage account= ${storageAccount}, storage container= ${container}, folder= ${folder}`,\n },\n FAILED_TO_GET_WORKSPACE_METADATA: {\n key: \"FailedToGetWorkspaceMetadata\",\n message: \"Failed to get workspace metadata\",\n formatWithError: (error: string): string => error,\n },\n TEST_RUN_CREATION_FAILED: {\n key: \"TestRunCreationFailed\",\n message: \"Failed to create test run. Test execution will continue.\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to create test run. Error: ${errorDetails}. Test execution will continue.`,\n },\n REPORTING_TEST_RUN_FAILED: {\n key: \"ReportingTestRunFailed\",\n message: \"Test run creation failed during setup.\",\n },\n REPORTER_REQUIRES_SERVICE_CONFIG: {\n key: \"ReporterRequiresServiceConfig\",\n message:\n \"Playwright Workspaces Reporter requires the use of service configuration via createAzurePlaywrightConfig. For more information, see https://aka.ms/pww-reporting.\",\n },\n};\n"],
5
- "mappings": "AAGO,MAAM,+BAA+B;AAAA,EAC1C,sBAAsB;AAAA,IACpB,KAAK;AAAA,IACL,SACE;AAAA,EACJ;AAAA,EACA,yBAAyB;AAAA,IACvB,KAAK;AAAA,IACL,SAAS;AAAA,EACX;AAAA,EACA,kCAAkC;AAAA,IAChC,KAAK;AAAA,IACL,SACE;AAAA,EACJ;AAAA,EACA,0CAA0C;AAAA,IACxC,KAAK;AAAA,IACL,SACE;AAAA,EACJ;AAAA,EACA,8CAA8C;AAAA,IAC5C,KAAK;AAAA,IACL,SACE;AAAA,EACJ;AAAA,EAC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AAA,IACT,wBAAwB,CAAC,iBACvB,qCAAqC,YAAY;AAAA,EACrD;AAAA,EACA,2BAA2B;AAAA,IACzB,KAAK;AAAA,IACL,SAAS;AAAA,EACX;AAAA,EACA,kCAAkC;AAAA,IAChC,KAAK;AAAA,IACL,SACE;AAAA,EACJ;AACF;",
6
- "names": []
7
- }
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/common/messages.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,4BAA4B,GAAG;IAC1C,oBAAoB,EAAE;QACpB,GAAG,EAAE,mBAAmB;QACxB,OAAO,EACL,8GAA8G;KACjH;IACD,uBAAuB,EAAE;QACvB,GAAG,EAAE,uBAAuB;QAC5B,OAAO,EAAE,qCAAqC;KAC/C;IACD,gCAAgC,EAAE;QAChC,GAAG,EAAE,+BAA+B;QACpC,OAAO,EACL,0IAA0I;KAC7I;IACD,wCAAwC,EAAE;QACxC,GAAG,EAAE,qCAAqC;QAC1C,OAAO,EACL,8KAA8K;KACjL;IACD,4CAA4C,EAAE;QAC5C,GAAG,EAAE,yCAAyC;QAC9C,OAAO,EACL,4IAA4I;KAC/I;IACD,wBAAwB,EAAE;QACxB,GAAG,EAAE,oBAAoB;QACzB,OAAO,EACL,mHAAmH;KACtH;IACD,uBAAuB,EAAE;QACvB,GAAG,EAAE,qBAAqB;QAC1B,OAAO,EACL,kKAAkK;KACrK;IACD,yBAAyB,EAAE;QACzB,GAAG,EAAE,uBAAuB;QAC5B,OAAO,EACL,2GAA2G;KAC9G;IACD,qBAAqB,EAAE;QACrB,GAAG,EAAE,oBAAoB;QACzB,OAAO,EACL,iGAAiG;KACpG;IACD,qBAAqB,EAAE;QACrB,GAAG,EAAE,oBAAoB;QACzB,OAAO,EAAE,+EAA+E;KACzF;IACD,wBAAwB,EAAE;QACxB,GAAG,EAAE,sBAAsB;QAC3B,OAAO,EACL,sLAAsL;KACzL;IACD,yBAAyB,EAAE;Q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CAAgC,EAAE;QAChC,GAAG,EAAE,8BAA8B;QACnC,OAAO,EAAE,kCAAkC;QAC3C,eAAe,EAAE,CAAC,KAAa,EAAU,EAAE,CAAC,KAAK;KAClD;IACD,wBAAwB,EAAE;QACxB,GAAG,EAAE,uBAAuB;QAC5B,OAAO,EAAE,0DAA0D;QACnE,sBAAsB,EAAE,CAAC,YAAoB,EAAU,EAAE,CACvD,qCAAqC,YAAY,iCAAiC;KACrF;IACD,yBAAyB,EAAE;QACzB,GAAG,EAAE,wBAAwB;QAC7B,OAAO,EAAE,wCAAwC;KAClD;IACD,gCAAgC,EAAE;QAChC,GAAG,EAAE,+BAA+B;QACpC,OAAO,EACL,mKAAmK;KACtK;CACF,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const ServiceErrorMessageConstants = {\n NO_SERVICE_URL_ERROR: {\n key: \"NoServiceUrlError\",\n message:\n \"The value for the PLAYWRIGHT_SERVICE_URL variable is not set correctly. Please verify the URL and try again.\",\n },\n INVALID_GLOBAL_FUNCTION: {\n key: \"InvalidGlobalFunction\",\n message: \"File must export a single function.\",\n },\n INVALID_PLAYWRIGHT_VERSION_ERROR: {\n key: \"InvalidPlaywrightVersionError\",\n message:\n \"The Playwright version you are using is not supported. See the list of supported versions at https://aka.ms/pww/docs/supported-versions.\",\n },\n PLAYWRIGHT_VERSION_TOO_OLD_FOR_REPORTING: {\n key: \"PlaywrightVersionTooOldForReporting\",\n message:\n \"To use the Playwright Workspaces reporting feature, you need Playwright version 1.57 or later installed. Update the Playwright package to a supported version and try again.\",\n },\n MULTIPLE_SETUP_FILE_PLAYWRIGHT_VERSION_ERROR: {\n key: \"MultipleSetupFilePlaywrightVersionError\",\n message:\n \"The Playwright version you are using does not support multiple setup/teardown files. Please update to Playwright version 1.49.0 or higher.\",\n },\n WORKSPACE_MISMATCH_ERROR: {\n key: \"InvalidAccessToken\",\n message:\n \"The provided access token does not match the specified workspace URL. Please verify that both values are correct.\",\n },\n NO_AUTH_ERROR_PAT_TOKEN: {\n key: \"NoAuthErrorPatToken\",\n message:\n \"Please set PLAYWRIGHT_SERVICE_ACCESS_TOKEN env variable when using ACCESS_TOKEN authentication. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n NO_AUTH_ERROR_ENTRA_TOKEN: {\n key: \"NoAuthErrorEntraToken\",\n message:\n \"Could not authenticate with the service. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n INVALID_MPT_PAT_ERROR: {\n key: \"InvalidMptPatError\",\n message:\n \"The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided is invalid. Please make sure to set a valid token.\",\n },\n EXPIRED_MPT_PAT_ERROR: {\n key: \"ExpiredMptPatError\",\n message: \"The PLAYWRIGHT_SERVICE_ACCESS_TOKEN provided has expired. Create a new token.\",\n },\n NO_CRED_ENTRA_AUTH_ERROR: {\n key: \"NoCredEntraAuthError\",\n message:\n \"Missing 'credential' parameter which is required when using ENTRA_ID authentication, Azure credential not provided. See https://aka.ms/pww/docs/authentication for more information.\",\n },\n FAILED_TO_CREATE_TEST_RUN: {\n key: \"FailedToCreateTestRun\",\n message:\n \"Failed to create the test run in the Playwright workspaces. For more information, see https://aka.ms/pww/docs/troubleshooting\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to create the test run in the Playwright workspaces. Error: ${errorDetails}. For more information, see https://aka.ms/pww/docs/troubleshooting`,\n },\n INVALID_PARAM_WITH_SERVICE_CONFIG: {\n key: \"InvalidParamWithServiceConfig\",\n message: `Remove serviceAuth, runId, and runName from getConnectOptions when using createAzurePlaywrightConfig. Configure these options through createAzurePlaywrightConfig instead.`,\n },\n INVALID_RUN_ID_FORMAT: {\n key: \"InvalidRunIdFormat\",\n message: \"The Run ID must be a valid GUID format. Please provide a valid GUID for the Run ID.\",\n },\n INVALID_AUTH_TYPE_ERROR: {\n key: \"InvalidAuthTypeError\",\n message: \"Invalid authentication type specified. Please use either ENTRA_ID or ACCESS_TOKEN.\",\n },\n FAILED_TO_GET_WORKSPACE_DETAILS: {\n key: \"FailedToGetWorkspaceDetails\",\n message: \"Failed to retrieve workspace details from the Playwright service.\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to retrieve workspace details from the Playwright service. Error: ${errorDetails}. Please verify your service URL and authentication credentials.`,\n },\n STORAGE_URI_NOT_FOUND: {\n key: \"StorageUriNotFound\",\n message: \"Storage Account is not linked with this Playwright Workspace.\",\n },\n STORAGE_AUTHORIZATION_FAILED: {\n key: \"StorageAuthorizationFailed\",\n message:\n \"The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account. For more information, see https://aka.ms/pww-reporting\",\n formatWithStorageAccount: (storageAccountName: string): string =>\n `The user is not authorized to perform this operation. Please make sure you have the Storage Blob Data Contributor role assigned to the storage account - ${storageAccountName}. For more information, see https://aka.ms/pww-reporting`,\n },\n UNABLE_TO_EXTRACT_WORKSPACE_ID: {\n key: \"UnableToExtractWorkspaceId\",\n message: \"Unable to extract workspace ID from service URL\",\n },\n STORAGE_ACCOUNT_DELETED: {\n key: \"StorageAccountDeleted\",\n message:\n \"The storage account linked to your Playwright Workspace may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration\",\n formatWithStorageAccount: (storageAccountName: string): string =>\n `The storage account linked to your Playwright Workspace (${storageAccountName}) may have been deleted. Please link a different storage account to your Playwright Workspace before trying again. To learn more on how to link a new storage account, refer to https://aka.ms/pww-reporting-migration`,\n },\n REPORTER_REQUIRES_ENTRA_AUTH: {\n key: \"ReporterRequiresEntraAuth\",\n message:\n \"Playwright Workspaces Reporter can only be used with ENTRA_ID authentication. For more information, see https://aka.ms/pww/docs/authentication\",\n },\n HTML_REPORTER_REQUIRED: {\n key: \"HtmlReporterRequired\",\n message:\n \"Playwright Workspaces Reporter requires the 'html' reporter to be configured in your Playwright configuration. Please add the 'html' reporter before playwright workspace reporter to generate test reports that can be uploaded to Azure Storage. Example: reporter: [['html'], ['@azure/playwright/reporter']]. For more information, see https://aka.ms/pww-reporting\",\n },\n WORKSPACE_METADATA_FETCH_FAILED: {\n key: \"WorkspaceMetadataFetchFailed\",\n message:\n \"Failed to retrieve workspace configuration. Reporting will be disabled for this run. Please check your authentication credentials and service URL.\",\n },\n WORKSPACE_REPORTING_DISABLED: {\n key: \"WorkspaceReportingDisabled\",\n message:\n \"Playwright Workspaces reporting: DISABLED. Reporting is not enabled for the Playwright Workspace. To learn more about how to enable reporting and link a storage account, see https://aka.ms/pww-reporting\",\n },\n WORKSPACE_REPORTING_STORAGE_NOT_LINKED: {\n key: \"WorkspaceReportingStorageNotLinked\",\n message:\n \"Playwright Workspaces reporting: DISABLED. Reporting is enabled for the Playwright Workspace, but no storage account is linked. Please link a storage account to enable reporting. For more information, see https://aka.ms/pww-reporting\",\n },\n UPLOAD_FAILED_FILES: {\n key: \"UploadFailedFiles\",\n message: \"Upload failed: files could not be uploaded\",\n formatWithCount: (failed: number): string =>\n `Upload failed: ${failed} files could not be uploaded`,\n },\n PLAYWRIGHT_TEST_REPORT_NOT_FOUND: {\n key: \"PlaywrightTestReportNotFound\",\n message: \"Playwright test report not found\",\n formatWithFolder: (folderName: string): string =>\n `Playwright test report not found: ${folderName}. For more information, see https://aka.ms/pww-reporting`,\n },\n REPORTING_ENABLED: {\n key: \"ReportingEnabled\",\n message: \"Playwright Workspaces reporting: ENABLED\",\n },\n COLLECTING_ARTIFACTS: {\n key: \"CollectingArtifacts\",\n message: \"Collecting artifacts: screenshots, videos, traces.\",\n },\n REPORTING_STATUS_SUCCESS: {\n key: \"ReportingStatusSuccess\",\n message: \"Reporting upload status: SUCCESS\",\n },\n REPORTING_STATUS_PARTIAL: {\n key: \"ReportingStatusPartial\",\n message: \"Reporting upload status: Partially Uploaded\",\n },\n REPORTING_STATUS_FAILED: {\n key: \"ReportingStatusFailed\",\n message: \"Reporting upload status: FAILED\",\n },\n TEST_REPORT_VIEW_URL: {\n key: \"TestReportViewUrl\",\n message: \"Published report URL: \",\n formatWithUrl: (url: string): string => `Published report URL: ${url}`,\n },\n UPLOADING_ARTIFACTS: {\n key: \"UploadingArtifacts\",\n message: \"Uploading artifacts to storage\",\n formatWithDetails: (storageAccount: string, container: string, folder: string): string =>\n `Uploading artifacts to: storage account= ${storageAccount}, storage container= ${container}, folder= ${folder}`,\n },\n FAILED_TO_GET_WORKSPACE_METADATA: {\n key: \"FailedToGetWorkspaceMetadata\",\n message: \"Failed to get workspace metadata\",\n formatWithError: (error: string): string => error,\n },\n TEST_RUN_CREATION_FAILED: {\n key: \"TestRunCreationFailed\",\n message: \"Failed to create test run. Test execution will continue.\",\n formatWithErrorDetails: (errorDetails: string): string =>\n `Failed to create test run. Error: ${errorDetails}. Test execution will continue.`,\n },\n REPORTING_TEST_RUN_FAILED: {\n key: \"ReportingTestRunFailed\",\n message: \"Test run creation failed during setup.\",\n },\n REPORTER_REQUIRES_SERVICE_CONFIG: {\n key: \"ReporterRequiresServiceConfig\",\n message:\n \"Playwright Workspaces Reporter requires the use of service configuration via createAzurePlaywrightConfig. For more information, see https://aka.ms/pww-reporting.\",\n },\n};\n"]}
@@ -1,102 +1,102 @@
1
- import {
2
- Constants,
3
- DefaultConnectOptionsConstants,
4
- InternalEnvironmentVariables,
5
- ServiceAuth
6
- } from "./constants.js";
1
+ // Copyright (c) Microsoft Corporation.
2
+ // Licensed under the MIT License.
3
+ import { Constants, DefaultConnectOptionsConstants, InternalEnvironmentVariables, ServiceAuth, } from "./constants.js";
7
4
  import { getAndSetRunId, getRunName, ValidateRunID } from "../utils/utils.js";
8
5
  import { CIInfoProvider } from "../utils/cIInfoProvider.js";
9
6
  import { state } from "./state.js";
10
7
  import { ServiceErrorMessageConstants } from "./messages.js";
11
8
  class PlaywrightServiceConfig {
12
- serviceOs;
13
- runId;
14
- connectTimeout;
15
- slowMo;
16
- exposeNetwork;
17
- runName;
18
- apiVersion;
19
- _serviceAuthType = ServiceAuth.ENTRA_ID;
20
- credential;
21
- constructor() {
22
- this.serviceOs = process.env[InternalEnvironmentVariables.MPT_SERVICE_OS] || DefaultConnectOptionsConstants.DEFAULT_SERVICE_OS;
23
- this.runName = process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] || "";
24
- this.runId = process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID] || "";
25
- this.connectTimeout = DefaultConnectOptionsConstants.DEFAULT_TIMEOUT;
26
- this.slowMo = DefaultConnectOptionsConstants.DEFAULT_SLOW_MO;
27
- this.exposeNetwork = DefaultConnectOptionsConstants.DEFAULT_EXPOSE_NETWORK;
28
- this.apiVersion = process.env[InternalEnvironmentVariables.MPT_API_VERSION] || Constants.LatestAPIVersion;
29
- }
30
- static get instance() {
31
- if (!state.playwrightServiceConfig) {
32
- state.playwrightServiceConfig = new PlaywrightServiceConfig();
9
+ serviceOs;
10
+ runId;
11
+ connectTimeout;
12
+ slowMo;
13
+ exposeNetwork;
14
+ runName;
15
+ apiVersion;
16
+ _serviceAuthType = ServiceAuth.ENTRA_ID;
17
+ credential;
18
+ constructor() {
19
+ this.serviceOs = (process.env[InternalEnvironmentVariables.MPT_SERVICE_OS] ||
20
+ DefaultConnectOptionsConstants.DEFAULT_SERVICE_OS);
21
+ this.runName = process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] || "";
22
+ this.runId = process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID] || "";
23
+ this.connectTimeout = DefaultConnectOptionsConstants.DEFAULT_TIMEOUT;
24
+ this.slowMo = DefaultConnectOptionsConstants.DEFAULT_SLOW_MO;
25
+ this.exposeNetwork = DefaultConnectOptionsConstants.DEFAULT_EXPOSE_NETWORK;
26
+ this.apiVersion =
27
+ process.env[InternalEnvironmentVariables.MPT_API_VERSION] || Constants.LatestAPIVersion;
33
28
  }
34
- return state.playwrightServiceConfig;
35
- }
36
- get serviceAuthType() {
37
- return this._serviceAuthType;
38
- }
39
- set serviceAuthType(value) {
40
- this._serviceAuthType = value;
41
- }
42
- async initialize() {
43
- if (!this.runName) {
44
- const ciConfigInfo = CIInfoProvider.getCIInfo();
45
- this.runName = await getRunName(ciConfigInfo);
29
+ static get instance() {
30
+ if (!state.playwrightServiceConfig) {
31
+ state.playwrightServiceConfig = new PlaywrightServiceConfig();
32
+ }
33
+ return state.playwrightServiceConfig;
46
34
  }
47
- }
48
- validateOptions = (options) => {
49
- if (!options) return;
50
- const isUsingServiceConfig = process.env[InternalEnvironmentVariables.USING_SERVICE_CONFIG] === "true";
51
- if (isUsingServiceConfig) {
52
- if (options.serviceAuthType || options.runId || options.runName) {
53
- const errorMessage = ServiceErrorMessageConstants.INVALID_PARAM_WITH_SERVICE_CONFIG.message;
54
- throw new Error(errorMessage);
55
- }
56
- return;
35
+ get serviceAuthType() {
36
+ return this._serviceAuthType;
57
37
  }
58
- };
59
- setOptions = (options, isGetConnectOptions = false) => {
60
- if (isGetConnectOptions) {
61
- this.validateOptions(options);
38
+ set serviceAuthType(value) {
39
+ this._serviceAuthType = value;
62
40
  }
63
- if (options?.exposeNetwork) {
64
- this.exposeNetwork = options.exposeNetwork;
41
+ async initialize() {
42
+ if (!this.runName) {
43
+ const ciConfigInfo = CIInfoProvider.getCIInfo();
44
+ this.runName = await getRunName(ciConfigInfo);
45
+ }
65
46
  }
66
- if (options?.apiVersion) {
67
- if (!process.env[InternalEnvironmentVariables.MPT_API_VERSION]) {
68
- process.env[InternalEnvironmentVariables.MPT_API_VERSION] = options.apiVersion;
69
- }
70
- this.apiVersion = options.apiVersion;
71
- }
72
- if (!process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID]) {
73
- if (options?.runId) {
74
- ValidateRunID(options.runId);
75
- this.runId = options.runId;
76
- process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID] = this.runId;
77
- } else {
78
- this.runId = getAndSetRunId();
79
- }
80
- }
81
- if (!process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] && options?.runName) {
82
- this.runName = options.runName;
83
- process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] = this.runName;
84
- }
85
- if (options?.os) {
86
- this.serviceOs = options.os;
87
- process.env[InternalEnvironmentVariables.MPT_SERVICE_OS] = this.serviceOs;
88
- }
89
- if (options?.slowMo) {
90
- this.slowMo = options.slowMo;
91
- }
92
- if (options?.connectTimeout) {
93
- this.connectTimeout = options.connectTimeout;
94
- }
95
- if (options?.credential) {
96
- this.credential = options.credential;
97
- }
98
- };
47
+ validateOptions = (options) => {
48
+ if (!options)
49
+ return;
50
+ const isUsingServiceConfig = process.env[InternalEnvironmentVariables.USING_SERVICE_CONFIG] === "true";
51
+ if (isUsingServiceConfig) {
52
+ if (options.serviceAuthType || options.runId || options.runName) {
53
+ const errorMessage = ServiceErrorMessageConstants.INVALID_PARAM_WITH_SERVICE_CONFIG.message;
54
+ throw new Error(errorMessage);
55
+ }
56
+ return;
57
+ }
58
+ };
59
+ setOptions = (options, isGetConnectOptions = false) => {
60
+ if (isGetConnectOptions) {
61
+ this.validateOptions(options);
62
+ }
63
+ if (options?.exposeNetwork) {
64
+ this.exposeNetwork = options.exposeNetwork;
65
+ }
66
+ if (options?.apiVersion) {
67
+ if (!process.env[InternalEnvironmentVariables.MPT_API_VERSION]) {
68
+ process.env[InternalEnvironmentVariables.MPT_API_VERSION] = options.apiVersion;
69
+ }
70
+ this.apiVersion = options.apiVersion;
71
+ }
72
+ if (!process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID]) {
73
+ if (options?.runId) {
74
+ ValidateRunID(options.runId);
75
+ this.runId = options.runId;
76
+ process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_ID] = this.runId;
77
+ }
78
+ else {
79
+ this.runId = getAndSetRunId();
80
+ }
81
+ }
82
+ if (!process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] && options?.runName) {
83
+ this.runName = options.runName;
84
+ process.env[InternalEnvironmentVariables.MPT_SERVICE_RUN_NAME] = this.runName;
85
+ }
86
+ if (options?.os) {
87
+ this.serviceOs = options.os;
88
+ process.env[InternalEnvironmentVariables.MPT_SERVICE_OS] = this.serviceOs;
89
+ }
90
+ if (options?.slowMo) {
91
+ this.slowMo = options.slowMo;
92
+ }
93
+ if (options?.connectTimeout) {
94
+ this.connectTimeout = options.connectTimeout;
95
+ }
96
+ if (options?.credential) {
97
+ this.credential = options.credential;
98
+ }
99
+ };
99
100
  }
100
- export {
101
- PlaywrightServiceConfig
102
- };
101
+ export { PlaywrightServiceConfig };
102
+ //# sourceMappingURL=playwrightServiceConfig.js.map