This repository was archived by the owner on Sep 21, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +29
-14
lines changed
Expand file tree Collapse file tree 4 files changed +29
-14
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ var _ = require('lodash'),
1111
1212 absolutePath = _ . partial ( path . resolve , REPORT_OUT_DIR ) ;
1313
14-
1514/**
1615 * @param {String } kind - одно из значение 'ref', 'current', 'diff'
1716 * @param {StateResult } result
Original file line number Diff line number Diff line change 8181 user-select : none;
8282}
8383
84+ .section__title_skipped {
85+ color : # ccc ;
86+ cursor : default;
87+
88+ -moz-user-select : text;
89+ -webkit-user-select : text;
90+ -ms-user-select : text;
91+ user-select : text;
92+ }
93+
8494.section__title : before , .meta-info__switcher : before {
8595 display : inline-block;
8696 margin-right : 2px ;
Original file line number Diff line number Diff line change 1313 {{ #each browsers }}
1414 <div class =" section section_collapsed {{ section-status }} {{ has-retries }} " >
1515 {{ #if result.skipped }}
16- {{ #if result.reason }}
17- <div class =" section__title" >[skipped] {{ result.name }} , reason: {{ result.reason }} </div >
18- {{ /if }}
19- {{ #unless result.reason }}
20- <div class =" section__title" >[skipped] {{ result.name }} </div >
21- {{ /unless }}
16+ <div class =" section__title section__title_skipped" >
17+ {{ #if result.reason }}
18+ [skipped] {{ result.name }} , reason: {{{ result.reason }}}
19+ {{ /if }}
20+ {{ #unless result.reason }}
21+ [skipped] {{ result.name }}
22+ {{ /unless }}
23+ </div >
2224 {{ /if }}
2325 {{ #unless result.skipped }}
2426 <div class =" section__title" >
Original file line number Diff line number Diff line change @@ -18,17 +18,15 @@ module.exports = class ViewModel {
1818 * @param {StateResult } result
1919 */
2020 addSkipped ( result ) {
21+ const comment = result . suite . skipComment && wrapLinkByTag ( result . suite . skipComment ) ;
22+
23+ this . _skips . push ( { suite : result . suite . fullName , browser : result . browserId , comment} ) ;
24+
2125 this . _addTestResult ( result , {
2226 skipped : true ,
23- reason : result . suite . skipComment
27+ reason : comment
2428 } ) ;
2529
26- const comment = result . suite . skipComment
27- && result . suite . skipComment . replace ( / h t t p s ? : \/ \/ [ ^ \s ] * / g, ( url ) => {
28- return `<a target="_blank" href="${ url } ">${ url } </a>` ;
29- } ) ;
30- this . _skips . push ( { suite : result . suite . fullName , browser : result . browserId , comment} ) ;
31-
3230 this . _counter . onSkipped ( result ) ;
3331 }
3432
@@ -208,3 +206,9 @@ function findOrCreate(node, statePath) {
208206
209207 return findOrCreate ( child , statePath ) ;
210208}
209+
210+ function wrapLinkByTag ( text ) {
211+ return text . replace ( / h t t p s ? : \/ \/ [ ^ \s ] * / g, ( url ) => {
212+ return `<a target="_blank" href="${ url } ">${ url } </a>` ;
213+ } ) ;
214+ }
You can’t perform that action at this time.
0 commit comments