forked from maciejmaciejewski/azure-pipelines-protractor
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtab-build.html
121 lines (108 loc) · 2.5 KB
/
tab-build.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<script src="lib/VSS.SDK.min.js"></script>
<script type="text/javascript">
VSS.init({
usePlatformScripts: true,
moduleLoaderConfig: {
paths: {"enhancer": "scripts"}
}
});
let noop = function () {
};
VSS.ready(function () {
require(["dist/protractor-tab"], noop);
VSS.notifyLoadSucceeded();
});
VSS.register("registeredEnvironmentObject", {
updateContext: noop
});
VSS.register("registerRelease", {
updateContext: noop,
isInvisible: function (state) {
let protractorTaskId = "f921c333-68d3-50ff-9d01-c71ecafad96b"
let resultArray = []
state.releaseEnvironment.deployPhasesSnapshot.forEach(phase => {
phase.workflowTasks.forEach(task => {
resultArray.push(task.taskId)
})
})
return !resultArray.includes(protractorTaskId)
}
});
</script>
<style>
html, body {
background-color: transparent !important;
margin: 0;
padding: 0;
}
#result {
display: none;
}
.wide {
position: absolute;
top: 20px;
left: 0;
width: 100%;
height: 96%;
border: 1px solid #ddd;
background-color: #F8F8F8;
box-shadow: 0 2px 6px 2px rgba(0, 0, 0, .05);
}
#protractor-result {
display: none
}
#waiting p {
padding: 0;
margin: auto 0;
font-family: arial, serif;
text-align: center;
position: relative;
top: 50%;
color: #ccc;
font-size: 30px;
}
.error-badge {
background-image: url("images/error.png");
width: 100px;
height: 100px;
display: none;
position: relative;
margin: auto;
top: 45%;
}
.spinner {
width: 100px;
height: 100px;
border: 1px solid #ccc;
border-top: 5px solid #E32E34;
border-radius: 50%;
position: relative;
top: 45%;
margin: auto;
animation: spin 2s infinite linear;
}
@keyframes spin {
from{
transform: rotate(0deg);
}to{
transform: rotate(360deg);
}
}
</style>
</head>
<body>
<div id="container">
<div id="waiting" class="wide">
<div class="spinner"></div>
<div class="error-badge"></div>
<p>Waiting for task results...</p>
</div>
<iframe id="protractor-result" class="wide" src="about:blank"></iframe>
</div>
</body>
</html>