Skip to content

Commit ae86d83

Browse files
author
Timon Riemslagh
committed
ZD523046 - design for unit test ribbon
1 parent bce12b7 commit ae86d83

File tree

3 files changed

+53
-6
lines changed

3 files changed

+53
-6
lines changed

OrbitOne.BuildScreen/OrbitOne.BuildScreen.RestApiService/VsoRestService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ private IEnumerable<BuildInfoDto> GetBuildsForPollingSince(string teamProjectNam
7373
FinishBuildDateTime = build.FinishTime,
7474
RequestedByName = build.RequestedFor.DisplayName,
7575
RequestedByPictureUrl = build.RequestedFor.ImageUrl + "&size=2",
76-
TotalNumberOfTests = 0,
76+
TotalNumberOfTests = 12,
7777
PassedNumberOfTests = 0,
7878
BuildReportUrl = _helperClass.ConvertReportUrl(teamProjectName, build.Uri, true),
7979
Id = "VSO" + teamProjectId + build.Definition.Id

OrbitOne.BuildScreen/OrbitOne.BuildScreen/Content/Site.css

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -500,3 +500,49 @@ body {
500500
.error-container.ng-hide {
501501
top: -50px;
502502
}
503+
504+
/*----------- CSS RIBBON -----------*/
505+
506+
.ribbon {
507+
position: absolute;
508+
right: -5px; top: -5px;
509+
z-index: 1;
510+
overflow: hidden;
511+
width: 75px; height: 75px;
512+
text-align: right;
513+
}
514+
.ribbon span {
515+
font-size: 10px;
516+
font-weight: bold;
517+
color: #FFF;
518+
text-transform: uppercase;
519+
text-align: center;
520+
line-height: 20px;
521+
transform: rotate(45deg);
522+
-webkit-transform: rotate(45deg);
523+
width: 100px;
524+
display: block;
525+
background: #79A70A;
526+
background: linear-gradient(#2989D8 0%, #2989D8 100%);
527+
box-shadow: 0 3px 10px -5px rgba(0, 0, 0, 1);
528+
position: absolute;
529+
top: 19px; right: -21px;
530+
}
531+
.ribbon span::before {
532+
content: "";
533+
position: absolute; left: 0px; top: 100%;
534+
z-index: -1;
535+
border-left: 3px solid #2989D8;
536+
border-right: 3px solid transparent;
537+
border-bottom: 3px solid transparent;
538+
border-top: 3px solid #2989D8;
539+
}
540+
.ribbon span::after {
541+
content: "";
542+
position: absolute; right: 0px; top: 100%;
543+
z-index: -1;
544+
border-left: 3px solid transparent;
545+
border-right: 3px solid #2989D8;
546+
border-bottom: 3px solid transparent;
547+
border-top: 3px solid #2989D8;
548+
}

OrbitOne.BuildScreen/OrbitOne.BuildScreen/Scripts/App/Templates/BuildDirectiveTemplate.html

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
<div class="item" ng-class="[build.Status, isStatusImportant(build.Status) ? 'wrapper-large' : 'wrapper']">
1+
<div class="item box" ng-class="[build.Status, isStatusImportant(build.Status) ? 'wrapper-large' : 'wrapper']">
2+
<div ng-if="build.TotalNumberOfTests > 0" class="ribbon"><span>{{build.PassedNumberOfTests}}/{{build.TotalNumberOfTests}}</span></div>
23

34
<span id="dateFilter" data-date="{{build.StartBuildDateTime}}" /> <!--This is because of Isotope/Angular compatibility problem-->
45

@@ -25,21 +26,21 @@
2526
<div ng-switch-when="failed" class="circle">
2627
<div class="builderror-label">
2728
<p>
28-
Build<br />failed
29+
Build<br/>failed
2930
</p>
3031
</div>
3132
</div>
3233
<div ng-switch-when="stopped" class="circle">
3334
<div class="builderror-label">
3435
<p>
35-
Build<br />stopped
36+
Build<br/>stopped
3637
</p>
3738
</div>
3839
</div>
3940
<div ng-switch-when="notStarted" class="circle">
4041
<div class="builderror-label">
4142
<p>
42-
Not<br />started
43+
Not<br/>started
4344
</p>
4445
</div>
4546
</div>
@@ -52,7 +53,7 @@
5253
</a>
5354
</div>
5455
<div class="avatar" ng-if="isStatusImportant(build.Status)">
55-
<img no-avatar ng-src="{{build.RequestedByPictureUrl}}" alt="avatar" />
56+
<img no-avatar ng-src="{{build.RequestedByPictureUrl}}" alt="avatar"/>
5657
</div>
5758
</div>
5859
</div>

0 commit comments

Comments
 (0)