Examples of message()


Examples of org.sonar.api.test.MutableTestCase.message()

    MutableTestCase testCase = mock(MutableTestCase.class);
    when(testCase.name()).thenReturn(name);
    when(testCase.status()).thenReturn(status);
    when(testCase.durationInMs()).thenReturn(durationInMs);
    when(testCase.countCoveredLines()).thenReturn(coveredLines);
    when(testCase.message()).thenReturn(message);
    when(testCase.stackTrace()).thenReturn(stackTrace);
    return testCase;
  }

}
View Full Code Here

Examples of org.sonar.core.activity.Activity.message()

    dbSession.commit();
    assertThat(index.findAll().getTotal()).isEqualTo(1);

    Activity activity = Iterables.getFirst(index.findAll().getHits(), null);
    assertThat(activity).isNotNull();
    assertThat(activity.message()).isEqualTo(testValue);
  }

  @Test
  public void insert_find_loggable_log() {
    final String testKey = "message";
View Full Code Here

Examples of org.sonar.core.i18n.DefaultI18n.message()

  @Test
  public void shouldSaveLinks() {
    Settings settings = new Settings();
    settings.setProperty(CoreProperties.LINKS_HOME_PAGE, "http://home");
    DefaultI18n defaultI18n = mock(DefaultI18n.class);
    when(defaultI18n.message(Locale.getDefault(), "project_links.homepage", CoreProperties.LINKS_HOME_PAGE)).thenReturn("HOME");
    Project project = mock(Project.class);
    SensorContext context = mock(SensorContext.class);

    new ProjectLinksSensor(settings, defaultI18n).analyse(project, context);
View Full Code Here

Examples of org.sonar.server.issue.index.IssueDoc.message()

    IssueDoc manualIssue = (IssueDoc) indexClient.get(IssueIndex.class).getByKey(result.key());
    assertThat(manualIssue.componentUuid()).isEqualTo(file.uuid());
    assertThat(manualIssue.projectUuid()).isEqualTo(project.uuid());
    assertThat(manualIssue.ruleKey()).isEqualTo(manualRule.getKey());
    assertThat(manualIssue.message()).isEqualTo("Fix it");
    assertThat(manualIssue.line()).isEqualTo(10);
    assertThat(manualIssue.severity()).isEqualTo(Severity.MINOR);
    assertThat(manualIssue.effortToFix()).isEqualTo(2d);
    assertThat(manualIssue.reporter()).isEqualTo(connectedUser.getLogin());
  }
View Full Code Here

Examples of org.sonar.wsclient.system.Migration.message()

    DefaultSystemClient client = new DefaultSystemClient(requestFactory);
    Migration migration = client.migrate(500L, 5L);

    assertThat(migration.status()).isEqualTo(Migration.Status.MIGRATION_SUCCEEDED);
    assertThat(migration.operationalWebapp()).isTrue();
    assertThat(migration.message()).isEqualTo("done");
    assertThat(migration.startedAt()).isNull();
  }

  @Test
  public void fail_if_missing_state() {
View Full Code Here

Examples of org.springmodules.validation.bean.conf.loader.annotation.handler.Email.message()

    @Override
    public String convertToValang(String fieldName, Annotation a, MessageSourceAccessor messages) {
        Email annotation = (Email) a;

        String errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
        String applyIfValang = valangToJS(annotation.applyIf());

        StringBuffer sb = new StringBuffer();
        sb.append(" function() {return this.equals((this.EmailFunction(this.getPropertyValue(");
        sb.append(wrapAndEscapeJsString(fieldName)); // name
View Full Code Here

Examples of org.springmodules.validation.bean.conf.loader.annotation.handler.Expression.message()

    @Override
    public String convertToValang(String fieldName, Annotation a, MessageSourceAccessor messages) {
        Expression annotation = (Expression) a;

        String errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
        String applyIfValang = valangToJS(annotation.applyIf());
        String expression = valangToJS(annotation.value());

        return buildBasicRule(fieldName, errMsg, expression, applyIfValang, annotation);
    }
View Full Code Here

Examples of org.springmodules.validation.bean.conf.loader.annotation.handler.InTheFuture.message()

            errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
            pastFutureMethod = "lessThan";
            applyIfValang = valangToJS(annotation.applyIf());
        } else if (a instanceof InTheFuture) {
            InTheFuture annotation = (InTheFuture) a;
            errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
            pastFutureMethod = "moreThan";
            applyIfValang = valangToJS(annotation.applyIf());
        }

        StringBuffer sb = new StringBuffer();
View Full Code Here

Examples of org.springmodules.validation.bean.conf.loader.annotation.handler.InThePast.message()

        String pastFutureMethod = "";
        String applyIfValang = null;

        if (a instanceof InThePast) {
            InThePast annotation = (InThePast) a;
            errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
            pastFutureMethod = "lessThan";
            applyIfValang = valangToJS(annotation.applyIf());
        } else if (a instanceof InTheFuture) {
            InTheFuture annotation = (InTheFuture) a;
            errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
View Full Code Here

Examples of org.springmodules.validation.bean.conf.loader.annotation.handler.Length.message()

        int max = 0;
        String applyIfValang = null;

        if (a instanceof Length) {
            Length annotation = (Length) a;
            errMsg = messages.getMessage(annotation.errorCode(), annotation.message());
            min = annotation.min();
            max = annotation.max();
            applyIfValang = valangToJS(annotation.applyIf());
        } else if (a instanceof Size) {
            Size annotation = (Size) a;
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.