Sha256: 4c7fe8a624868ceff5a484f1e7b0ca408d4e4ec13307a589e0925ff473b4a610

Contents?: true

Size: 1.97 KB

Versions: 73

Compression:

Stored size: 1.97 KB

Contents

import org.junit.Ignore;
import org.junit.Test;
import static org.junit.Assert.assertEquals;

public class TwoBucketTest {
	
	@Test
	public void testBucketOneSizeThreeBucketTwoSizeFiveStartWithOne() {
		
		TwoBucket twoBucket = new TwoBucket(3, 5, 1, "one");
		
		assertEquals(4, twoBucket.getTotalMoves());
		assertEquals("one", twoBucket.getFinalBucket());
		assertEquals(5, twoBucket.getOtherBucket());
		
	}
	
	@Ignore("Remove to run test")
	@Test
	public void testBucketOneSizeThreeBucketTwoSizeFiveStartWithTwo() {
		
		TwoBucket twoBucket = new TwoBucket(3, 5, 1, "two");
		
		assertEquals(8, twoBucket.getTotalMoves());
		assertEquals("two", twoBucket.getFinalBucket());
		assertEquals(3, twoBucket.getOtherBucket());
		
	}
	
	@Ignore("Remove to run test")
	@Test
	public void testBucketOneSizeSevenBucketTwoSizeElevenStartWithOne() {
		
		TwoBucket twoBucket = new TwoBucket(7, 11, 2, "one");
		
		assertEquals(14, twoBucket.getTotalMoves());
		assertEquals("one", twoBucket.getFinalBucket());
		assertEquals(11, twoBucket.getOtherBucket());
		
	}
	
	@Ignore("Remove to run test")
	@Test
	public void testBucketOneSizeSevenBucketTwoSizeElevenStartWithTwo() {
		
		TwoBucket twoBucket = new TwoBucket(7, 11, 2, "two");
		
		assertEquals(18, twoBucket.getTotalMoves());
		assertEquals("two", twoBucket.getFinalBucket());
		assertEquals(7, twoBucket.getOtherBucket());
		
	}
	
	@Ignore("Remove to run test")
	@Test
	public void testBucketOneSizeOneBucketTwoSizeThreeStartWithTwo() {
		
		TwoBucket twoBucket = new TwoBucket(1, 3, 3, "two");
		
		assertEquals(1, twoBucket.getTotalMoves());
		assertEquals("two", twoBucket.getFinalBucket());
		assertEquals(0, twoBucket.getOtherBucket());
		
	}
	
	@Ignore("Remove to run test")
	@Test
	public void testBucketOneSizeTwoBucketTwoSizeThreeStartWithOne() {
		
		TwoBucket twoBucket = new TwoBucket(2, 3, 3, "one");
		
		assertEquals(2, twoBucket.getTotalMoves());
		assertEquals("two", twoBucket.getFinalBucket());
		assertEquals(2, twoBucket.getOtherBucket());
		
	}
}

Version data entries

73 entries across 73 versions & 1 rubygems

Version Path
trackler-2.2.1.139 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.138 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.137 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.136 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.135 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.134 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.133 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.132 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.131 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.130 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.129 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.128 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.127 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.126 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.125 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.124 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.123 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.122 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.121 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.120 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java