samples/individualsamples/test/org/apidesign/samples/CodeThatCanBeCalledOnlyByTestTest.java
author Jaroslav Tulach <jaroslav.tulach@apidesign.org>
Thu, 30 Oct 2014 20:46:27 +0100
changeset 408 9a439a79c6d0
permissions -rw-r--r--
Use scala 2.10.4 to compile on JDK8
     1 package org.apidesign.samples;
     2 
     3 import org.junit.Test;
     4 import static org.junit.Assert.*;
     5 
     6 public class CodeThatCanBeCalledOnlyByTestTest {
     7 
     8     public CodeThatCanBeCalledOnlyByTestTest() {
     9     }
    10 
    11     @Test
    12     public void setNumber() {
    13         CodeThatCanBeCalledOnlyByTest.setNumber(111);
    14         assertEquals(
    15             "Changing number is OK from tests", 
    16             111, 
    17             CodeThatCanBeCalledOnlyByTest.getNumber()
    18         );
    19     }
    20 
    21 }