/** Testet die Method {@link org.log.datas.LogDataFactory#messageNoOut(String, String)}. */ @Test public void testMessageNoOut() { _data = LogDataFactory.messageNoOut(_message, _error); assertThat(_data.getMessage(), is(_message)); assertThat(_data.getError(), is(_error)); assertThat(_data.getOut(), is(LogData.NO_OUT)); }
/** Testet die Methode {@link org.log.datas.LogDataFactory#messageWarning(String, String)}. */ @Test public void testMessageWarning() { _data = LogDataFactory.messageWarning(_message, _error); assertThat(_data.getMessage(), is(_message)); assertThat(_data.getError(), is(_error)); assertThat(_data.getOut(), is(LogData.WARNING)); }
/** * Testet die Methode {@link org.log.datas.LogDataFactory#messageDatabaseInsert(String, * Exception)}. */ @Test public void testMessageDatabaseInsert() { _data = LogDataFactory.messageDatabaseInsert(_message, _error); assertThat(_data.getMessage(), is(_message)); assertThat(_data.getError(), is(_error)); assertThat(_data.getOut(), is(LogData.DATABASE_INSERT)); }
/** Testet die Methode {@link org.log.datas.LogDataFactory#message(String, Exception)}. */ @Test public void testMessageStackTrace() { Exception exception = new Exception(); _data = LogDataFactory.message(_message, exception); assertThat(_data.getMessage(), is(_message)); assertThat(_data.getError(), is(LogData.createError(exception))); assertThat(_data.getOut(), is(LogData.NONE)); }
/** * Testet die Methode {@link org.log.datas.LogDataFactory#messageDatabaseInsert(String, * Exception)}. */ @Test public void testMessageDatabaseInsertStackTrace() { Exception exception = new Exception(); _data = LogDataFactory.messageDatabaseInsert(_message, exception); assertThat(_data.getMessage(), is(_message)); assertThat(_data.getError(), is(LogData.createError(exception))); assertThat(_data.getOut(), is(LogData.DATABASE_INSERT)); }