这根本不会发生任何报道。你能看出原因吗?谢谢!
CGFloat height = 200;
[self.containerView applyHeightConstrain:height];
//完成测试后调用的回调函数。
[self.containerView accessAppliedConstraintByAttribute:NSLayoutAttributeHeight completion:^(NSLayoutConstraint *expectedConstraint){
if (expectedConstraint) {
expectedConstraint.constant = 100;
/* for the animation */
[self.containerView updateModifyConstraintsWithAnimation:NULL];
}
}];
//为html输出调用自定义报告
onPrepare: function() {
var jasmineReporters = require('jasmine-reporters');
var capsPromise = browser.getCapabilities();
return capsPromise.then(function(caps){
var browserName = caps.caps_.browserName;
});
jasmine.getEnv().addReporter(new jasmineReporters.JUnitXmlReporter({
consolidateAll: false,
savePath: 'C:/QA/test_results/'
}));
},
答案 0 :(得分:1)
到达“return”语句时,onPrepare函数会停止。实际上从不调用addReporter函数。
您应该添加jasmineReporter 然后来存储您的浏览器功能。尝试这样的事情:
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="sha384-1q8mTJOASx8j1Au+a5WDVnPi2lkFfwwEAa8hDDdjZlpLegxhjVME1fgjWPGmkzs7" crossorigin="anonymous">
<!-- Optional theme -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css" integrity="sha384-fLW2N01lMqjakBkx3l/M9EahuwpSfeNvV63J5ezn3uZzapT0u7EYsXMjQV+0En5r" crossorigin="anonymous">
<!-- Latest compiled and minified JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" integrity="sha384-0mSbJDEHialfmuBBQP6A4Qrprq5OVfW37PRR3j5ELqxss1yVqOtnepnHVP9aJ7xS" crossorigin="anonymous"></script>
<div class="container">
<div class="row feature-description">
<div class="col-lg-4">
<div class="start-up-phase">
<h4 class="phase-title"><strong>START UP PHASE</strong></h4>
<div class="phase-content">
Startup phase is very crucial as reseller develop their first business partners group and hands on learning about their business culture, products and other important skills with the support of the leaders. At this point, reseller will get the most from
own effort and rewarded from the initial group development.
<?php load_helper( 'html'); echo br(4) ?>
<p>
High Margin Retail Opportunities, Personal Residual Income, Introducer Bonus and Group Placement Incentive dedicated for reseller in this phase.
</p>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="growth-phase">
<h4 class="phase-title">
<strong>START UP PHASE</strong>
</h4>
<div class="phase-content">
Startup phase is very crucial as reseller develop their first business partners group and hands on learning about their business culture, products and other important skills with the support of the leaders. At this point, reseller will get the most from
own effort and rewarded from the initial group development.
</div>
</div>
</div>
<div class="col-lg-4">
<div class="expansion-phase">
<h4 class="phase-title">
<strong>START UP PHASE</strong>
</h4>
<div class="phase-content">
Startup phase is very crucial as reseller develop their first business partners group and hands on learning about their business culture, products and other important skills with the support of the leaders. At this point, reseller will get the most from
own effort and rewarded from the initial group development.
</div>
</div>
</div>
</div>
答案 1 :(得分:0)
最新的selenium服务器中的cap_method发生了变化。尝试这样的事情: 而不是:
return capsPromise.then(function (caps) {
browserName = caps.caps_.browserName.toLowerCase();
browserName = browserName.replace(/ /g,"-");
browserVersion = caps.caps_.version;
return null;
});
使用此:
browser.getCapabilities().then(function(c){
console.log(c.get('browserName'));
browserName = c.get('browserName').toLowerCase();
browserName = browserName.replace(/ /g,"-");
browserVersion = c.get('version');
return null;
});
我可以从xml生成html但是,html中的testbrowser值显示为'undefined'。