form
元素上使用Bootstrap的col-xs-*
类!这样,无论屏幕分辨率有多宽,我们的复选框都会均匀分布在整个页面上。将所有三个复选框嵌套在<div class="row">
元素中。然后将它们嵌套在<div class="col-xs-4">
元素中。 div
带有类row
div
。
testString: assert($("div.row:has(input[type=\"checkbox\"])").length > 0);
- text: 使用类col-xs-4
将每个复选框嵌入其自己的div
。
testString: assert($("div.col-xs-4:has(input[type=\"checkbox\"])").length > 2);
- text: 确保每个div
元素都有一个结束标记。
testString: assert(code.match(/<\/div>/g) && code.match(/