Add E2E test - general-user-settings-tab.spec.ts (#10658)

* Add E2E test: `general-user-settings-tab.spec.ts`

Initial implementation

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* lint

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Check an input area for a new email address too

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
This commit is contained in:
Suguru Hirahara 2023-04-20 13:18:19 +00:00 committed by GitHub
parent 483b53c148
commit 467c52a2ae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 229 additions and 3 deletions

View file

@ -468,7 +468,7 @@ export default class GeneralUserSettingsTab extends React.Component<IProps, ISta
private renderManagementSection(): JSX.Element {
// TODO: Improve warning text for account deactivation
return (
<div className="mx_SettingsTab_section">
<div className="mx_SettingsTab_section" data-testid="account-management-section">
<span className="mx_SettingsTab_subheading">{_t("Account management")}</span>
<span className="mx_SettingsTab_subsectionText">
{_t("Deactivating your account is a permanent action — be careful!")}
@ -528,8 +528,10 @@ export default class GeneralUserSettingsTab extends React.Component<IProps, ISta
}
return (
<div className="mx_SettingsTab">
<div className="mx_SettingsTab_heading">{_t("General")}</div>
<div className="mx_SettingsTab mx_GeneralUserSettingsTab">
<div className="mx_SettingsTab_heading" data-testid="general">
{_t("General")}
</div>
{this.renderProfileSection()}
{this.renderAccountSection()}
{this.renderLanguageSection()}