Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add some tests for bar #1328

Merged
merged 9 commits into from
Apr 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

### Added
- Add type column to scan configs to allow filter and sort by scan config type [#1331](https://github.com/greenbone/gsa/pull/1331)
- Add some tests for bar components [#1328](https://github.com/greenbone/gsa/pull/1328)
- Add new DefaultFilterSettings to UserSettings [#1326](https://github.com/greenbone/gsa/pull/1326)
- Add warning for IE11 [#1322](https://github.com/greenbone/gsa/pull/1322)
- Add tests for label and img [#1313](https://github.com/greenbone/gsa/pull/1313)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`ProgressBar tests should render 1`] = `
.c0 {
height: 13px;
box-sizing: content-box;
display: inline-block;
width: 100px;
background: #393637;
vertical-align: middle;
text-align: center;
}

.c2 {
z-index: 1;
font-weight: bold;
color: #fff;
font-size: 9px;
margin: 0;
position: relative;
top: -13px;
padding-top: 1px;
}

.c1 {
height: 13px;
width: 10%;
background: #4F91C7;
}

@media print {
.c0 {
background: none;
border: 0;
}
}

@media print {
.c2 {
color: black;
}
}

@media print {
.c1 {
background: none;
}
}

<div
class="c0"
data-testid="progressbar-box"
title="Progress"
>
<div
class="c1"
data-testid="progress"
/>
<div
class="c2"
/>
</div>
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`SeverityBar tests should render 1`] = `
.c0 {
height: 13px;
box-sizing: content-box;
display: inline-block;
width: 100px;
background: #393637;
vertical-align: middle;
text-align: center;
}

.c2 {
z-index: 1;
font-weight: bold;
color: #fff;
font-size: 9px;
margin: 0;
position: relative;
top: -13px;
padding-top: 1px;
}

.c1 {
height: 13px;
width: 95%;
background: #C83814;
}

@media print {
.c0 {
background: none;
border: 0;
}
}

@media print {
.c2 {
color: black;
}
}

@media print {
.c1 {
background: none;
}
}

<div
class="c0"
data-testid="progressbar-box"
title="High"
>
<div
class="c1"
data-testid="progress"
/>
<div
class="c2"
>
9.5 (High)
</div>
</div>
`;
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,12 @@ exports[`StatusBar tests should render 1`] = `

<div
class="c0"
data-testid="progressbar-box"
title="undefined"
>
<div
class="c1"
data-testid="progress"
/>
<div
class="c2"
Expand Down
Loading