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
1527fd7b
Commit
1527fd7b
authored
Feb 27, 2020
by
Heinrich Lee Yu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove changelog and tweaked tests
Improves test assertion to check on the right text span
parent
2e8e34bd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
9 deletions
+7
-9
ee/changelogs/unreleased/208229-haml-scoped-labels-incorrect-text-color.yml
...leased/208229-haml-scoped-labels-incorrect-text-color.yml
+0
-5
ee/spec/helpers/ee/labels_helper_spec.rb
ee/spec/helpers/ee/labels_helper_spec.rb
+7
-4
No files found.
ee/changelogs/unreleased/208229-haml-scoped-labels-incorrect-text-color.yml
deleted
100644 → 0
View file @
2e8e34bd
---
title
:
Fix scoped label text color when background is light
merge_request
:
26037
author
:
type
:
fixed
ee/spec/helpers/ee/labels_helper_spec.rb
View file @
1527fd7b
...
@@ -5,8 +5,7 @@ require 'spec_helper'
...
@@ -5,8 +5,7 @@ require 'spec_helper'
describe
LabelsHelper
do
describe
LabelsHelper
do
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:label
)
{
build_stubbed
(
:label
,
project:
project
).
present
(
issuable_subject:
nil
)
}
let
(
:label
)
{
build_stubbed
(
:label
,
project:
project
).
present
(
issuable_subject:
nil
)
}
let
(
:scoped_label
)
{
build_stubbed
(
:label
,
name:
'key::value'
,
project:
project
,
color:
'#D10069'
).
present
(
issuable_subject:
nil
)
}
let
(
:scoped_label
)
{
build_stubbed
(
:label
,
name:
'key::value'
,
project:
project
).
present
(
issuable_subject:
nil
)
}
let
(
:scoped_label2
)
{
build_stubbed
(
:label
,
name:
'key::value'
,
project:
project
,
color:
'#FFECDB'
).
present
(
issuable_subject:
nil
)
}
describe
'#render_label'
do
describe
'#render_label'
do
context
'with scoped labels enabled'
do
context
'with scoped labels enabled'
do
...
@@ -23,11 +22,15 @@ describe LabelsHelper do
...
@@ -23,11 +22,15 @@ describe LabelsHelper do
end
end
it
'right text span does not have .gl-label-text-dark class if label color is dark'
do
it
'right text span does not have .gl-label-text-dark class if label color is dark'
do
expect
(
render_label
(
scoped_label
)).
not_to
include
(
'gl-label-text-dark'
)
scoped_label
.
color
=
'#D10069'
expect
(
render_label
(
scoped_label
)).
not_to
match
(
%r(<span.*gl-label-text-dark.*>
#{
scoped_label
.
scoped_label_value
}
</span>)m
)
end
end
it
'right text span has .gl-label-text-dark class if label color is light'
do
it
'right text span has .gl-label-text-dark class if label color is light'
do
expect
(
render_label
(
scoped_label2
)).
to
include
(
'gl-label-text-dark'
)
scoped_label
.
color
=
'#FFECDB'
expect
(
render_label
(
scoped_label
)).
to
match
(
%r(<span.*gl-label-text-dark.*>
#{
scoped_label
.
scoped_label_value
}
</span>)m
)
end
end
end
end
...
...
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