Upgrade Playwright's dependencies (#28125)

* upgrade playwright's dependencies

* fix test

* fix types

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
This commit is contained in:
Saturnino Abril 2024-09-10 14:54:10 +08:00 committed by GitHub
parent c2df4e413e
commit eb560fff1e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 371 additions and 358 deletions

View File

@ -104,11 +104,11 @@
"CollapsedThreads": "disabled",
"ManagedResourcePaths": "",
"EnableCustomGroups": true,
"SelfHostedPurchase": true,
"AllowSyncedDrafts": true,
"UniqueEmojiReactionLimitPerPost": 50,
"RefreshPostStatsRunTime": "00:00",
"MaximumPayloadSizeBytes": 100000
"MaximumPayloadSizeBytes": 100000,
"MaximumURLLength": 2048
},
"TeamSettings": {
"SiteName": "Mattermost",
@ -296,8 +296,7 @@
"LoginFieldName": "",
"LoginButtonColor": "#0000",
"LoginButtonBorderColor": "#2389D7",
"LoginButtonTextColor": "#2389D7",
"Trace": false
"LoginButtonTextColor": "#2389D7"
},
"ComplianceSettings": {
"Enable": false,
@ -392,7 +391,6 @@
"CustomSMTPPort": "25"
}
},
"ProductSettings": {},
"PluginSettings": {
"Enable": true,
"EnableUploads": true,

View File

@ -105,11 +105,11 @@
"CollapsedThreads": "disabled",
"ManagedResourcePaths": "",
"EnableCustomGroups": true,
"SelfHostedPurchase": true,
"AllowSyncedDrafts": true,
"UniqueEmojiReactionLimitPerPost": 50,
"RefreshPostStatsRunTime": "00:00",
"MaximumPayloadSizeBytes": 100000
"MaximumPayloadSizeBytes": 100000,
"MaximumURLLength": 2048
},
"TeamSettings": {
"SiteName": "Mattermost",
@ -173,7 +173,6 @@
"VerboseDiagnostics": false,
"EnableSentry": false,
"AdvancedLoggingJSON": {},
"AdvancedLoggingConfig": "",
"MaxFieldSize": 2048
},
"ExperimentalAuditSettings": {
@ -184,8 +183,7 @@
"FileMaxBackups": 0,
"FileCompress": false,
"FileMaxQueueSize": 1000,
"AdvancedLoggingJSON": {},
"AdvancedLoggingConfig": ""
"AdvancedLoggingJSON": {}
},
"NotificationLogSettings": {
"EnableConsole": true,
@ -196,8 +194,7 @@
"FileLevel": "INFO",
"FileJson": true,
"FileLocation": "",
"AdvancedLoggingJSON": {},
"AdvancedLoggingConfig": ""
"AdvancedLoggingJSON": {}
},
"PasswordSettings": {
"MinimumLength": 5,
@ -404,8 +401,7 @@
"LoginFieldName": "",
"LoginButtonColor": "#0000",
"LoginButtonBorderColor": "#2389D7",
"LoginButtonTextColor": "#2389D7",
"Trace": false
"LoginButtonTextColor": "#2389D7"
},
"ComplianceSettings": {
"Enable": false,
@ -509,7 +505,7 @@
"AggregatePostsAfterDays": 365,
"PostsAggregatorJobStartTime": "03:00",
"IndexPrefix": "",
"LiveIndexingBatchSize": 1,
"LiveIndexingBatchSize": 10,
"BatchSize": 10000,
"RequestTimeoutSeconds": 30,
"SkipTLSVerification": false,
@ -563,7 +559,6 @@
"CleanupJobsThresholdDays": -1,
"CleanupConfigThresholdDays": -1
},
"ProductSettings": {},
"PluginSettings": {
"Enable": true,
"EnableUploads": true,

View File

@ -45,7 +45,7 @@ npm run test
Change to root directory, run docker container
```
docker run -it --rm -v "$(pwd):/mattermost/" --ipc=host mcr.microsoft.com/playwright:v1.43.0-jammy /bin/bash
docker run -it --rm -v "$(pwd):/mattermost/" --ipc=host mcr.microsoft.com/playwright:v1.46.1 /bin/bash
```
#### 2. Inside the docker container

File diff suppressed because it is too large Load Diff

View File

@ -15,18 +15,18 @@
"postinstall": "script/post_install.sh"
},
"dependencies": {
"@axe-core/playwright": "4.9.0",
"@percy/cli": "1.28.3",
"@percy/playwright": "1.0.5",
"@playwright/test": "1.43.1",
"@axe-core/playwright": "4.10.0",
"@percy/cli": "1.29.3",
"@percy/playwright": "1.0.6",
"@playwright/test": "1.46.1",
"async-wait-until": "2.0.12",
"axe-core": "4.9.0",
"axe-core": "4.10.0",
"chalk": "4.1.2",
"deepmerge": "4.3.1",
"dotenv": "16.4.5",
"form-data": "4.0.0",
"isomorphic-unfetch": "4.0.2",
"uuid": "9.0.1"
"uuid": "10.0.0"
},
"devDependencies": {
"@types/uuid": "9.0.8",

View File

@ -81,7 +81,7 @@ const onPremServerConfig = (): Partial<TestAdminConfig> => {
};
// Should be based only from the generated default config from ./server via "make config-reset"
// Based on v9.8 server
// Based on v10.0 server
const defaultServerConfig: AdminConfig = {
ServiceSettings: {
SiteURL: '',
@ -133,7 +133,7 @@ const defaultServerConfig: AdminConfig = {
CorsDebug: false,
AllowCookiesForSubdomains: false,
ExtendSessionLengthWithActivity: true,
TerminateSessionsOnPasswordChange: false,
TerminateSessionsOnPasswordChange: true,
SessionLengthWebInDays: 30,
SessionLengthWebInHours: 720,
SessionLengthMobileInDays: 30,
@ -191,11 +191,11 @@ const defaultServerConfig: AdminConfig = {
CollapsedThreads: CollapsedThreads.ALWAYS_ON,
ManagedResourcePaths: '',
EnableCustomGroups: true,
SelfHostedPurchase: true,
AllowSyncedDrafts: true,
UniqueEmojiReactionLimitPerPost: 50,
RefreshPostStatsRunTime: '00:00',
MaximumPayloadSizeBytes: 300000,
MaximumURLLength: 2048,
},
TeamSettings: {
SiteName: 'Mattermost',
@ -260,7 +260,6 @@ const defaultServerConfig: AdminConfig = {
VerboseDiagnostics: false,
EnableSentry: true,
AdvancedLoggingJSON: {},
AdvancedLoggingConfig: '',
MaxFieldSize: 2048,
},
ExperimentalAuditSettings: {
@ -272,7 +271,6 @@ const defaultServerConfig: AdminConfig = {
FileCompress: false,
FileMaxQueueSize: 1000,
AdvancedLoggingJSON: {},
AdvancedLoggingConfig: '',
},
NotificationLogSettings: {
EnableConsole: true,
@ -284,7 +282,6 @@ const defaultServerConfig: AdminConfig = {
FileJson: true,
FileLocation: '',
AdvancedLoggingJSON: {},
AdvancedLoggingConfig: '',
},
PasswordSettings: {
MinimumLength: 8,
@ -497,7 +494,6 @@ const defaultServerConfig: AdminConfig = {
LoginButtonColor: '#0000',
LoginButtonBorderColor: '#2389D7',
LoginButtonTextColor: '#2389D7',
Trace: false,
},
ComplianceSettings: {
Enable: false,
@ -552,6 +548,12 @@ const defaultServerConfig: AdminConfig = {
AndroidAppDownloadLink: 'https://mattermost.com/pl/android-app/',
IosAppDownloadLink: 'https://mattermost.com/pl/ios-app/',
},
CacheSettings: {
CacheType: 'lru',
RedisAddress: '',
RedisPassword: '',
RedisDB: -1,
},
ClusterSettings: {
Enable: false,
ClusterName: '',
@ -569,6 +571,8 @@ const defaultServerConfig: AdminConfig = {
Enable: false,
BlockProfileRate: 0,
ListenAddress: ':8067',
EnableClientMetrics: true,
EnableNotificationMetrics: true,
},
ExperimentalSettings: {
ClientSideCertEnable: false,
@ -580,6 +584,8 @@ const defaultServerConfig: AdminConfig = {
DisableAppBar: false,
DisableRefetchingOnBrowserFocus: false,
DelayChannelAutocomplete: false,
DisableWakeUpReconnectHandler: false,
UsersStatusAndProfileFetchingPollIntervalMilliseconds: 3000,
YoutubeReferrerPolicy: false,
},
AnalyticsSettings: {
@ -587,9 +593,9 @@ const defaultServerConfig: AdminConfig = {
},
ElasticsearchSettings: {
ConnectionURL: 'http://localhost:9200',
Backend: 'elasticsearch',
Username: 'elastic',
Password: 'changeme',
Backend: 'elasticsearch',
EnableIndexing: false,
EnableSearching: false,
EnableAutocomplete: false,
@ -603,7 +609,7 @@ const defaultServerConfig: AdminConfig = {
AggregatePostsAfterDays: 365,
PostsAggregatorJobStartTime: '03:00',
IndexPrefix: '',
LiveIndexingBatchSize: 1,
LiveIndexingBatchSize: 10,
BatchSize: 10000,
RequestTimeoutSeconds: 30,
SkipTLSVerification: false,
@ -657,7 +663,6 @@ const defaultServerConfig: AdminConfig = {
CleanupJobsThresholdDays: -1,
CleanupConfigThresholdDays: -1,
},
ProductSettings: {},
PluginSettings: {
Enable: true,
EnableUploads: false,
@ -712,14 +717,12 @@ const defaultServerConfig: AdminConfig = {
TestFeature: 'off',
TestBoolFeature: false,
EnableRemoteClusterService: false,
AppsEnabled: true,
AppsEnabled: false,
PermalinkPreviews: false,
CallsEnabled: true,
NormalizeLdapDNs: false,
WysiwygEditor: false,
OnboardingTourTips: true,
DeprecateCloudFree: false,
CloudReverseTrial: false,
EnableExportDirectDownload: false,
MoveThreadsEnabled: false,
StreamlinedMarketplace: true,
@ -728,8 +731,9 @@ const defaultServerConfig: AdminConfig = {
CloudAnnualRenewals: false,
CloudDedicatedExportUI: false,
ChannelBookmarks: false,
WebSocketEventScope: false,
WebSocketEventScope: true,
NotificationMonitoring: true,
ExperimentalAuditSettingsSystemConsoleUI: false,
},
ImportSettings: {
Directory: './import',

View File

@ -64,13 +64,6 @@ describe('components/admin_console/license_settings/enterprise_edition/enterpris
preferences: {
myPreferences: {},
},
admin: {
config: {
ServiceSettings: {
SelfHostedPurchase: true,
},
},
},
cloud: {
subscription: undefined,
},

View File

@ -385,7 +385,6 @@ export type ServiceSettings = {
DebugSplit: boolean;
ManagedResourcePaths: string;
EnableCustomGroups: boolean;
SelfHostedPurchase: boolean;
AllowSyncedDrafts: boolean;
AllowPersistentNotifications: boolean;
AllowPersistentNotificationsForGuests: boolean;
@ -395,6 +394,7 @@ export type ServiceSettings = {
UniqueEmojiReactionLimitPerPost: number;
RefreshPostStatsRunTime: string;
MaximumPayloadSizeBytes: number;
MaximumURLLength: number;
};
export type TeamSettings = {
@ -461,7 +461,6 @@ export type LogSettings = {
EnableDiagnostics: boolean;
VerboseDiagnostics: boolean;
EnableSentry: boolean;
AdvancedLoggingConfig: string;
AdvancedLoggingJSON: Record<string, any>;
MaxFieldSize: number;
};
@ -474,7 +473,6 @@ export type ExperimentalAuditSettings = {
FileMaxBackups: number;
FileCompress: boolean;
FileMaxQueueSize: number;
AdvancedLoggingConfig: string;
AdvancedLoggingJSON: Record<string, any>;
};
@ -487,7 +485,6 @@ export type NotificationLogSettings = {
FileLevel: string;
FileJson: boolean;
FileLocation: string;
AdvancedLoggingConfig: string;
AdvancedLoggingJSON: Record<string, any>;
};
@ -697,7 +694,6 @@ export type LdapSettings = {
LoginButtonColor: string;
LoginButtonBorderColor: string;
LoginButtonTextColor: string;
Trace: boolean;
};
export type ComplianceSettings = {
@ -775,6 +771,8 @@ export type MetricsSettings = {
Enable: boolean;
BlockProfileRate: number;
ListenAddress: string;
EnableClientMetrics: boolean;
EnableNotificationMetrics: boolean;
};
export type ExperimentalSettings = {
@ -787,6 +785,8 @@ export type ExperimentalSettings = {
DisableAppBar: boolean;
DisableRefetchingOnBrowserFocus: boolean;
DelayChannelAutocomplete: boolean;
DisableWakeUpReconnectHandler: boolean;
UsersStatusAndProfileFetchingPollIntervalMilliseconds: number;
YoutubeReferrerPolicy: boolean;
};
@ -794,6 +794,13 @@ export type AnalyticsSettings = {
MaxUsersForStatistics: number;
};
export type CacheSettings = {
CacheType: string;
RedisAddress: string;
RedisPassword: string;
RedisDB: number;
};
export type ElasticsearchSettings = {
ConnectionURL: string;
Backend: string;
@ -871,8 +878,6 @@ export type JobSettings = {
CleanupConfigThresholdDays: number;
};
export type ProductSettings = Record<string, never>;
export type PluginSettings = {
Enable: boolean;
EnableUploads: boolean;
@ -959,12 +964,12 @@ export type AdminConfig = {
MetricsSettings: MetricsSettings;
ExperimentalSettings: ExperimentalSettings;
AnalyticsSettings: AnalyticsSettings;
CacheSettings: CacheSettings;
ElasticsearchSettings: ElasticsearchSettings;
BleveSettings: BleveSettings;
DataRetentionSettings: DataRetentionSettings;
MessageExportSettings: MessageExportSettings;
JobSettings: JobSettings;
ProductSettings: ProductSettings;
PluginSettings: PluginSettings;
DisplaySettings: DisplaySettings;
GuestAccountsSettings: GuestAccountsSettings;