Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
f1b675b1
Unverified
Commit
f1b675b1
authored
Dec 19, 2019
by
Hugo Häggmark
Committed by
GitHub
Dec 19, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
e2e: Waits for login before moving forward (#21185)
parent
06761892
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
3 deletions
+12
-3
packages/grafana-e2e/src/flows/login.ts
+6
-0
packages/grafana-e2e/src/pages/login.ts
+1
-0
public/app/core/components/Login/ChangePassword.tsx
+5
-3
No files found.
packages/grafana-e2e/src/flows/login.ts
View file @
f1b675b1
...
...
@@ -8,5 +8,11 @@ export const login = (username: string, password: string) => {
.
type
(
username
);
e2e
.
pages
.
Login
.
password
().
type
(
password
);
e2e
.
pages
.
Login
.
submit
().
click
();
e2e
.
pages
.
Login
.
skip
()
.
should
(
'be.visible'
)
.
click
();
e2e
()
.
get
(
'.login-page'
)
.
should
(
'not.exist'
);
e2e
().
logToConsole
(
'Logged in with'
,
{
username
,
password
});
};
packages/grafana-e2e/src/pages/login.ts
View file @
f1b675b1
...
...
@@ -6,5 +6,6 @@ export const Login = pageFactory({
username
:
'Username input field'
,
password
:
'Password input field'
,
submit
:
'Login button'
,
skip
:
'Skip change password button'
,
},
});
public/app/core/components/Login/ChangePassword.tsx
View file @
f1b675b1
import
React
,
{
PureComponent
,
SyntheticEvent
,
Change
Event
}
from
'react'
;
import
React
,
{
ChangeEvent
,
PureComponent
,
Synthetic
Event
}
from
'react'
;
import
{
Tooltip
}
from
'@grafana/ui'
;
import
appEvents
from
'app/core/app_events'
;
import
{
AppEvents
}
from
'@grafana/data'
;
import
{
e2e
}
from
'@grafana/e2e'
;
import
appEvents
from
'app/core/app_events'
;
interface
Props
{
onSubmit
:
(
pw
:
string
)
=>
void
;
...
...
@@ -115,7 +117,7 @@ export class ChangePassword extends PureComponent<Props, State> {
placement=
"bottom"
content=
"If you skip you will be prompted to change password next time you login."
>
<
a
className=
"btn btn-link"
onClick=
{
this
.
onSkip
}
>
<
a
className=
"btn btn-link"
onClick=
{
this
.
onSkip
}
aria
-
label=
{
e2e
.
pages
.
Login
.
selectors
.
skip
}
>
Skip
</
a
>
</
Tooltip
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment