Skip to content

lean-mind/workshop-introduction-refactoring-java

Repository files navigation

Workshop introduction refactoring in Java

Use Maven to open this project and copy the contents of the file corresponding to the installed Java version (java8-pom.txt or java11-pom.txt) into the pom.xml file.

In this repository you will find the first 3 exercises of our course of advanced refactoring:

Prerequisites

In order to run this workshop you will need to have installed the Intellij IDE https://www.jetbrains.com/idea/

Exercises

  • Exercise 1:

    The aim of this exercise is for you to understand how values and references work in Java. You must complete the tests in the file youShouldUnderstandValuesAndReferences.java , getting them to pass.

  • Exercise 2:

    In this second exercise, you must change the price attribute of the shopping cart to a price list:

    List<Integer> prices;

    You must make sure that the tests keep passing.

  • Exercise 2 - Second iteration:

    When you have the price list, you must change the type of the variable from integer to a Price object.

  • Exercise 3:

    You must convert the Id parameter to a value object. Remember to check that the tests are green.

About

In this repository you will find the first 3 exercises of our course of advanced refactoring

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages