Examples of ActiveRuleDto


Examples of org.sonar.core.qualityprofile.db.ActiveRuleDto

    RuleKey ruleKey = RuleTesting.XOO_X1;
    RuleDto ruleDto = newRuleDto(ruleKey);
    db.ruleDao().insert(dbSession, ruleDto);

    ActiveRuleDto activeRule1 = ActiveRuleDto.createFor(profileDto1, ruleDto).setSeverity(Severity.MAJOR);
    ActiveRuleDto activeRule2 = ActiveRuleDto.createFor(profileDto2, ruleDto).setSeverity(Severity.MAJOR);
    db.activeRuleDao().insert(dbSession, activeRule1, activeRule2);
    dbSession.commit();

    // 0. Test base case
    assertThat(index.get(ActiveRuleIndex.class).countAll()).isEqualTo(2);
View Full Code Here

Examples of org.sonar.core.qualityprofile.db.ActiveRuleDto

    RuleKey ruleKey = RuleTesting.XOO_X1;
    RuleDto ruleDto = newRuleDto(ruleKey);
    db.ruleDao().insert(dbSession, ruleDto);

    ActiveRuleDto activeRule1 = ActiveRuleDto.createFor(profileDto1, ruleDto).setSeverity(Severity.MAJOR);
    ActiveRuleDto activeRule2 = ActiveRuleDto.createFor(profileDto2, ruleDto).setSeverity(Severity.MAJOR);
    db.activeRuleDao().insert(dbSession, activeRule1, activeRule2);
    dbSession.commit();

    // 0. Test base case
    assertThat(index.get(ActiveRuleIndex.class).countAll()).isEqualTo(2);
View Full Code Here

Examples of org.sonar.core.qualityprofile.db.ActiveRuleDto

      // TODO this should be generated by RegisterRule and modified in DTO.
      String parentKey = null;
      Integer parentId = activeRuleDto.getParentId();
      if (parentId != null) {
        ActiveRuleDto parentDto = db.activeRuleDao().getById(session, parentId);
        if (parentDto != null) {
          parentKey = parentDto.getKey().toString();
        }
      }

      /* Creating updateRequest */
      requests.add(new UpdateRequest()
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.