Skip to content

Learn. Write. Repeat.

  • Technical books I recommend
  • Food for thought
  • About me
  • Human engineering books I recommend

Category: Test your code

Test your code

Test doubles

October 21, 2016November 1, 2016 sergiuoltean

"Test Double is a generic term for any case where you replace a production object for testing purposes". This is how Martin Fowler describes it. They are mainly used in unit tests, when the unit must be tested in isolation. A little background If we are not testing the component in isolation, it's hard to cover… Continue reading Test doubles

1 Comment
Test your code

Fluent assertions in Junit

October 11, 2016November 1, 2016 sergiuoltean

Yes. Still Junit. We're not done with it yet. This is about how to make assertions using AssertJ. It's a cool library which is really easy to use and helps our tests look fluent and nicer. I'm not gonna go over all assertions that are available, I will just focus on some of them that… Continue reading Fluent assertions in Junit

1 Comment
Test your code

BDD with Junit

October 3, 2016November 1, 2016 sergiuoltean

Just recently, on 18th of September 2016 JGiven was released. So I wanted to know how does it look like and what can we do with it. As many of you already know BDD stands for Behavioural Driven Development. That means writing the test in a such a way that non-technical people(eg Business Analysts) would… Continue reading BDD with Junit

Leave a comment
Test your code

Junit Rules

September 27, 2016November 1, 2016 sergiuoltean

While this can be read in many ways, this is strictly referring to the @Rule annotation and TestRule interface that are  available for use in Junit. These are not widely used but they do help us in setting up tests and making the code more elegant and less verbose. What are they good for? Well they are good… Continue reading Junit Rules

Leave a comment
Test your code

Mutation testing

September 21, 2016June 26, 2019 sergiuoltean

Weak tests. Even with 100% coverage that does not mean the code is completely tested. See weak tests. What is it? Mutation testing is a structural testing technique, which uses the structure of the code to guide the testing process. Each mutated version is called a mutant. They need to be killed. Test suites are measured by… Continue reading Mutation testing

1 Comment

Posts navigation

Newer posts

Search

Categories

  • Architecture (3)
  • Database (3)
  • Deployment (1)
  • Design (3)
  • drools (3)
  • Food for thought (8)
  • Git (3)
  • human engineer (1)
  • Java (10)
  • Java Messages (1)
  • Kafka (2)
  • Maven (4)
  • Microservices (18)
  • Mysql (1)
  • Security (1)
  • Test your code (15)

Follow me on Twitter

My Tweets
Follow Learn. Write. Repeat. on WordPress.com
Blog at WordPress.com.
  • Follow Following
    • Learn. Write. Repeat.
    • Already have a WordPress.com account? Log in now.
    • Learn. Write. Repeat.
    • Customize
    • Follow Following
    • Sign up
    • Log in
    • Report this content
    • View site in Reader
    • Manage subscriptions
    • Collapse this bar
 

Loading Comments...
 

    Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
    To find out more, including how to control cookies, see here: Cookie Policy