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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
2ad630fb
Commit
2ad630fb
authored
Sep 21, 2016
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix deselecting calendar days on contribution graph
parent
5368b9f2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
46 additions
and
0 deletions
+46
-0
app/assets/javascripts/users/calendar.js
app/assets/javascripts/users/calendar.js
+1
-0
changelogs/unreleased/disable-calendar-deselection.yml
changelogs/unreleased/disable-calendar-deselection.yml
+4
-0
spec/features/calendar_spec.rb
spec/features/calendar_spec.rb
+41
-0
No files found.
app/assets/javascripts/users/calendar.js
View file @
2ad630fb
...
...
@@ -206,6 +206,7 @@
}
});
}
else
{
this
.
currentSelectedDate
=
''
;
return
$
(
'
.user-calendar-activities
'
).
html
(
''
);
}
};
...
...
changelogs/unreleased/disable-calendar-deselection.yml
0 → 100644
View file @
2ad630fb
---
title
:
Fix deselecting calendar days on contribution graph
merge_request
:
6453
author
:
ClemMakesApps
spec/features/calendar_spec.rb
View file @
2ad630fb
...
...
@@ -52,6 +52,10 @@ feature 'Contributions Calendar', js: true, feature: true do
Event
.
create
(
push_params
)
end
def
get_first_cell_content
find
(
'.user-calendar-activities'
).
text
end
before
do
login_as
:user
visit
@user
.
username
...
...
@@ -62,6 +66,43 @@ feature 'Contributions Calendar', js: true, feature: true do
expect
(
page
).
to
have_css
(
'.js-contrib-calendar'
)
end
describe
'select calendar day'
,
js:
true
do
let
(
:cells
)
{
page
.
all
(
'.user-contrib-cell'
)
}
let
(
:first_cell_content_before
)
{
get_first_cell_content
}
before
do
cells
[
0
].
click
wait_for_ajax
first_cell_content_before
end
it
'displays calendar day activities'
,
js:
true
do
expect
(
get_first_cell_content
).
not_to
eq
(
''
)
end
describe
'select another calendar day'
,
js:
true
do
before
do
cells
[
1
].
click
wait_for_ajax
end
it
'displays different calendar day activities'
,
js:
true
do
expect
(
get_first_cell_content
).
not_to
eq
(
first_cell_content_before
)
end
end
describe
'deselect calendar day'
,
js:
true
do
before
do
cells
[
0
].
click
wait_for_ajax
end
it
'hides calendar day activities'
,
js:
true
do
expect
(
get_first_cell_content
).
to
eq
(
''
)
end
end
end
describe
'1 calendar activity'
do
before
do
Issues
::
CreateService
.
new
(
contributed_project
,
@user
,
issue_params
).
execute
...
...
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