Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
c60b5cb8
Commit
c60b5cb8
authored
Jun 02, 2020
by
lauraMon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updates the specs
parent
cbcf5829
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
8 deletions
+9
-8
app/assets/javascripts/alert_management/components/alert_management_list.vue
...pts/alert_management/components/alert_management_list.vue
+1
-1
spec/frontend/alert_management/components/alert_management_list_spec.js
...alert_management/components/alert_management_list_spec.js
+8
-7
No files found.
app/assets/javascripts/alert_management/components/alert_management_list.vue
View file @
c60b5cb8
...
...
@@ -229,7 +229,7 @@ export default {
},
mounted
()
{
this
.
trackPageViews
();
if
(
this
.
alertManagementEnabled
)
{
if
(
this
.
alertManagementEnabled
)
{
findDefaultSortColumn
().
ariaSort
=
'
descending
'
;
}
},
...
...
spec/frontend/alert_management/components/alert_management_list_spec.js
View file @
c60b5cb8
...
...
@@ -48,7 +48,6 @@ describe('AlertManagementList', () => {
const
findAssignees
=
()
=>
wrapper
.
findAll
(
'
[data-testid="assigneesField"]
'
);
const
findSeverityFields
=
()
=>
wrapper
.
findAll
(
'
[data-testid="severityField"]
'
);
const
findSeverityColumnHeader
=
()
=>
wrapper
.
findAll
(
'
th
'
).
at
(
0
);
const
findStartTimeColumnHeader
=
()
=>
wrapper
.
findAll
(
'
th
'
).
at
(
1
);
const
findPagination
=
()
=>
wrapper
.
find
(
GlPagination
);
const
alertsCount
=
{
open
:
14
,
...
...
@@ -333,7 +332,12 @@ describe('AlertManagementList', () => {
beforeEach
(()
=>
{
mountComponent
({
props
:
{
alertManagementEnabled
:
true
,
userCanEnableAlertManagement
:
true
},
data
:
{
alerts
:
{
list
:
mockAlerts
},
errored
:
false
,
sort
:
'
STARTED_AT_ASC
'
,
alertsCount
},
data
:
{
alerts
:
{
list
:
mockAlerts
},
errored
:
false
,
sort
:
'
STARTED_AT_DESC
'
,
alertsCount
,
},
loading
:
false
,
stubs
:
{
GlTable
},
});
...
...
@@ -350,14 +354,11 @@ describe('AlertManagementList', () => {
});
it
(
'
updates the `ariaSort` attribute so the sort icon appears in the proper column
'
,
()
=>
{
expect
(
findStartTimeColumnHeader
().
attributes
(
'
aria-sort
'
)).
toBe
(
'
a
scending
'
);
expect
(
mockStartedAtCol
.
ariaSort
).
toEqual
(
'
de
scending
'
);
findSeverityColumnHeader
().
trigger
(
'
click
'
);
wrapper
.
vm
.
$nextTick
(()
=>
{
expect
(
findStartTimeColumnHeader
().
attributes
(
'
aria-sort
'
)).
toBe
(
'
none
'
);
expect
(
findSeverityColumnHeader
().
attributes
(
'
aria-sort
'
)).
toBe
(
'
ascending
'
);
});
expect
(
mockStartedAtCol
.
ariaSort
).
toEqual
(
'
none
'
);
});
});
...
...
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