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.159 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.158 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.157 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.156 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.155 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.154 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.153 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.152 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.151 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.150 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.149 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.148 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.147 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.146 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.145 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.144 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.143 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.142 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.141 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java
trackler-2.2.1.140 tracks/java/exercises/two-bucket/src/test/java/TwoBucketTest.java