package org.bukkit;
import static org.hamcrest.Matchers.*;
import static org.junit.Assert.*;
import java.util.List;
import java.util.Random;
import org.bukkit.util.Vector;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameter;
import org.junit.runners.Parameterized.Parameters;
import com.google.common.collect.ImmutableList;
@RunWith(Parameterized.class)
public class LocationTest {
private static final double δ = 1.0 / 1000000;
/**
*
* a² + b² = c², a = b
* => 2∙(a²) = 2∙(b²) = c², c = 1
* => 2∙(a²) = 1
* => a² = 1/2
* => a = √(1/2) ∎
*
*/
private static final double HALF_UNIT = Math.sqrt(1 / 2f);
/**
*
* a² + b² = c², c = √(1/2)
* => a² + b² = √(1/2)², a = b
* => 2∙(a²) = 2∙(b²) = 1/2
* => a² = 1/4
* => a = √(1/4) ∎
*
*/
private static final double HALF_HALF_UNIT = Math.sqrt(1 / 4f);
@Parameters(name= "{index}: {0}")
public static List