Posts tagged with "junit"

Sep 11th, 2012

Running HTTP/REST Integration tests in an Eclipse Tycho Build

reports

A few days ago my fellow Frank wrote about running HTTP/REST Integration Tests efficiently in Eclipse. Today I want to show you how to embed those tests in a headless build using Eclipse Tycho. Embedding restfuse in a build is as simple as embedding plain JUnit tests. But when trying to start an OSGi server [...]

Leave a Comment
Sep 10th, 2012

restfuse 1.1.1 released

restfuse

It has been almost a year since the last restfuse news. In the meantime restfuse was adopted by a lot of individuals and companies. Since the last release the development continued on github and made it now worthwhile to publish an update. Last week we released restfuse 1.1.1. Some noteworthy things are: Updated the underlying Jersey [...]

4 Comments
Aug 6th, 2012

Fuzzy Testing of Data/Model-centric applications

Many test cases for an application involve data defined by the data model. To achieve good test coverage it is customary to run the test cases for a variety of input data sets. This can be achieved by manually specifying input data. However, this is a complex task and it is easy to miss important [...]

Leave a Comment
Apr 26th, 2012

Eclipse Testing Day 2012 Submissions Open

This year marks the third Eclipse Testing Day, where the community gathers for a day focusing on testing with, for and at Eclipse. The event takes place on September 05 in Darmstadt. The general theme for this year’s testing day is “Testing and Beyond”. Topics of interest include: Testing Eclipse applications Testing within the Eclipse [...]

Leave a Comment
Mar 20th, 2012

Simple JUnit4 templates for Eclipse

Screen Shot 2012-03-20 at 12.24.04 PM

JUnit and Eclipse are a great combination, but one thing that I missed every time I worked with JUnit4 was the code templates. Currently, Eclipse ships with pre-defined templates for JUnit3 but not for JUnit4. So, I wrote three basic JUnit4 templates that can be imported from the “Templates” Preference Page. Take a look at [...]

1 Comment
Nov 16th, 2011

Effective Mockito Part 5

With this effective Mockito Post I want to share a really simple pattern with you. We call this pattern “check answers” and we use it whenever we work with Mockito Answers. The code resulting from creating Mockito Answers generally looks ugly. But, as good programmers we care about test quality, right? Let’s see how we [...]

2 Comments
Nov 14th, 2011

Introducing restfuse – a JUnit Extension to test REST APIs

For several projects at EclipseSource we are creating REST APIs. I’m involved in most of them and there is one thing that bothers me with every project. That is, testing. I mean, of course we are writing our unit tests first and we mock our services to get fast unit tests, but at some point [...]

9 Comments
Oct 13th, 2011

Effective Mockito Part 3

In the previous Effective Mockito post we saw how to use the @Mock Annotation to get a clean test. In this post I want to show you how to use Mockito’s spy mechanism to eliminate testing troubles with third party libraries. Testing is one of the most important things in software development. I assume you [...]

5 Comments
Oct 7th, 2009

Using JUnit’s “Assume” for faster tests

I wanted to share something I learned today about JUnit. Some of you may know this, but it was news to me. My triggering problem was that I was writing some unit-tests which required OSGi to be started up. All my other tests were plain (i.e. non-OSGi) tests. Since I didn’t want to suffer from [...]

1 Comment