Made the default XSL style less blocky.
authorMarkus Kauppila
Wed, 06 Jul 2011 23:49:36 +0300
changeset 574891a7152856f3
parent 5747 cba233c8f7fa
child 5749 0c63fb52e749
Made the default XSL style less blocky.
test/test-automation/skeleton.xsl
test/test-automation/style.xsl
     1.1 --- a/test/test-automation/skeleton.xsl	Wed Jul 06 17:05:07 2011 +0300
     1.2 +++ b/test/test-automation/skeleton.xsl	Wed Jul 06 23:49:36 2011 +0300
     1.3 @@ -125,7 +125,7 @@
     1.4  }
     1.5  	
     1.6  .title {
     1.7 -  font-weight: bold;
     1.8 +  font-weight: bold; 
     1.9  }	
    1.10  </style>
    1.11  	
     2.1 --- a/test/test-automation/style.xsl	Wed Jul 06 17:05:07 2011 +0300
     2.2 +++ b/test/test-automation/style.xsl	Wed Jul 06 23:49:36 2011 +0300
     2.3 @@ -102,22 +102,27 @@
     2.4  	$("div.asserts").hide();
     2.5  	
     2.6  	/* Color the tests based on the result */
     2.7 -	$("div.test[result='passed']").addClass('passed');
     2.8 -	$("div.test[result='failed']").addClass('failed');
     2.9 +	$("span.testResult[result='passed']").addClass('passed');
    2.10 +	$("span.testResult[result='failed']").addClass('failed');
    2.11  	
    2.12  	/* Color the asserts based on the result */
    2.13 -	$("div.assert[result='pass']").addClass('passed');
    2.14 -	$("div.assert[result='failure']").addClass('failed');
    2.15 +	$("span.assertResult[result='pass']").addClass('passed');
    2.16 +	$("span.assertResult[result='failure']").addClass('failed');
    2.17  });
    2.18  
    2.19  </script>
    2.20  <style>
    2.21  
    2.22  div, h1 {
    2.23 -  padding: 3px 10px 2px 10px;
    2.24 +  padding: 2px 10px 2px 10px;
    2.25    margin: 5px 0px 5px 0px;
    2.26  }
    2.27  
    2.28 +.assert {
    2.29 +  padding: 0px 10px 0px 10px;
    2.30 +  margin: 0px 0px 0px 0px;
    2.31 +}
    2.32 +
    2.33  .document {
    2.34    font-family: Arial;
    2.35    font-size: 11pt;
    2.36 @@ -139,17 +144,17 @@
    2.37  	
    2.38  .switch {
    2.39    font-style: italic;
    2.40 -  color: rgb(10, 10, 200); /*#024A68;*/
    2.41 +  color: rgb(10, 10, 200); 
    2.42    font-size: 10pt;
    2.43    cursor: pointer;
    2.44  }	
    2.45  	
    2.46  .passed {
    2.47 - background-color: #64AA2B;
    2.48 + color: green;
    2.49  }
    2.50  
    2.51  .failed {
    2.52 - background-color: #FF6E40;
    2.53 + color: red;
    2.54  }
    2.55  
    2.56  </style>
    2.57 @@ -193,33 +198,29 @@
    2.58          <div class="tests" uid="{generate-id(test)}">
    2.59  	      <xsl:for-each select="test">
    2.60  			<div class="test">
    2.61 +			Test <span class="title"><xsl:value-of select="name"/>: </span>
    2.62 +			<span class="testResult">
    2.63  			  <xsl:attribute name="result">
    2.64 -			    <xsl:value-of select="result"/>
    2.65 -	          </xsl:attribute>
    2.66 -		      
    2.67 -		      Name:  <xsl:value-of select="name"/> (<xsl:value-of select="startTime"/>  - <xsl:value-of select="endTime"/>  ) <br/>
    2.68 -		      Description: <span class="description"> <xsl:value-of select="description"/> </span><br/> 
    2.69 -		
    2.70 -	          Total runtime: <xsl:value-of select="totalRuntime"/> seconds  <br/>
    2.71 -		      Result: <xsl:value-of select="result"/>  <br/>
    2.72 -		      
    2.73 +			    <xsl:value-of select="result"/> 
    2.74 +	           </xsl:attribute><xsl:value-of select="result"/> 
    2.75 +	        </span> 
    2.76 +			(Total runtime: <xsl:value-of select="totalRuntime"/> seconds)<br/>
    2.77 +			Description: <span class="description"> <xsl:value-of select="description"/> </span><br/>
    2.78  		      <span class="switch show-asserts" uid="{generate-id(assertSummary)}">[Show Assert Summary]</span><br/>
    2.79  			  <div class="asserts" uid="{generate-id(assertSummary)}">
    2.80  		        <xsl:for-each select="assert"> 
    2.81  			      <div class="assert">
    2.82 -  			        <xsl:attribute name="result">
    2.83 -				      <xsl:value-of select="result"/>
    2.84 -				    </xsl:attribute>
    2.85 -		            Assert name: <xsl:value-of select="name"/> <br/>
    2.86 -		            Result: <xsl:value-of select="result"/> <br/>
    2.87 -		            Message <xsl:value-of select="message"/> <br/>
    2.88 -		            Time <xsl:value-of select="time"/> <br/>
    2.89 +					<xsl:value-of select="name"/>: 
    2.90 +					<span class="assertResult">
    2.91 +						<xsl:attribute name="result">
    2.92 +					      <xsl:value-of select="result"/>
    2.93 +					    </xsl:attribute>
    2.94 +					  <xsl:value-of select="result"/>  
    2.95 +					</span>.
    2.96 +					 Message: <span class="description"><xsl:value-of select="message"/></span>
    2.97  		          </div>
    2.98  		        </xsl:for-each>
    2.99 -		        AssertSummary:
   2.100 -		        Assert count: <xsl:value-of select="assertSummary/assertCount"/> <br/>
   2.101 -		        Asserts Passed <xsl:value-of select="assertSummary/assertsPassed"/> <br/>
   2.102 -		        Asserts Failed <xsl:value-of select="assertSummary/assertsFailed"/> <br/>
   2.103 +				Asserts in total: <xsl:value-of select="assertSummary/assertCount"/> (passed: <xsl:value-of select="assertSummary/assertsPassed"/>, failed: <xsl:value-of select="assertSummary/assertsFailed"/>)
   2.104  		      </div>
   2.105      		</div>
   2.106  		  </xsl:for-each>