}
@Test
public void define_rules() {
JavaScriptCommonRulesEngine engine = new JavaScriptCommonRulesEngine();
CommonRulesRepository repo = engine.newRepository();
assertThat(repo.rules()).hasSize(4);
assertThat(repo.rule(CommonRulesRepository.RULE_INSUFFICIENT_COMMENT_DENSITY)).isNotNull();
assertThat(repo.rule(CommonRulesRepository.RULE_DUPLICATED_BLOCKS)).isNotNull();
assertThat(repo.rule(CommonRulesRepository.RULE_INSUFFICIENT_LINE_COVERAGE)).isNotNull();
assertThat(repo.rule(CommonRulesRepository.RULE_INSUFFICIENT_BRANCH_COVERAGE)).isNotNull();
}