fix java code style
This commit is contained in:
parent
c8733803d9
commit
6dfe29a3fd
|
@ -25,9 +25,9 @@ import com.sun.jna.Pointer;
|
||||||
import com.sun.jna.Structure;
|
import com.sun.jna.Structure;
|
||||||
|
|
||||||
public interface GoInterface extends Library {
|
public interface GoInterface extends Library {
|
||||||
public String GetEndpoints(String namespace, String service, String seeds);
|
String GetEndpoints(String namespace, String service, String seeds);
|
||||||
|
|
||||||
public class GoSlice extends Structure {
|
class GoSlice extends Structure {
|
||||||
public static class ByValue extends GoSlice implements Structure.ByValue {
|
public static class ByValue extends GoSlice implements Structure.ByValue {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -36,11 +36,11 @@ public interface GoInterface extends Library {
|
||||||
public long cap;
|
public long cap;
|
||||||
|
|
||||||
protected List<String> getFieldOrder() {
|
protected List<String> getFieldOrder() {
|
||||||
return Arrays.asList(new String[] { "data", "len", "cap" });
|
return Arrays.asList("data", "len", "cap" );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public class GoString extends Structure {
|
class GoString extends Structure {
|
||||||
public static class ByValue extends GoString implements Structure.ByValue {
|
public static class ByValue extends GoString implements Structure.ByValue {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -48,7 +48,7 @@ public interface GoInterface extends Library {
|
||||||
public long n;
|
public long n;
|
||||||
|
|
||||||
protected List<String> getFieldOrder() {
|
protected List<String> getFieldOrder() {
|
||||||
return Arrays.asList(new String[] { "p", "n" });
|
return Arrays.asList("p", "n" );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -20,8 +20,10 @@ import static org.hamcrest.Matchers.empty;
|
||||||
import static org.hamcrest.Matchers.is;
|
import static org.hamcrest.Matchers.is;
|
||||||
import static org.hamcrest.Matchers.not;
|
import static org.hamcrest.Matchers.not;
|
||||||
import static org.junit.Assert.assertThat;
|
import static org.junit.Assert.assertThat;
|
||||||
|
import static org.junit.Assert.assertTrue;
|
||||||
|
|
||||||
import java.net.InetAddress;
|
import java.net.InetAddress;
|
||||||
|
import java.util.Collections;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -36,12 +38,12 @@ public class KubernetesSeedProviderTest {
|
||||||
private static final Logger logger = LoggerFactory.getLogger(KubernetesSeedProviderTest.class);
|
private static final Logger logger = LoggerFactory.getLogger(KubernetesSeedProviderTest.class);
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@Ignore("has to be run inside of a kube cluster")
|
@Ignore("has to be run inside of a kubernetes cluster")
|
||||||
public void getSeeds() throws Exception {
|
public void getSeeds() throws Exception {
|
||||||
SeedProvider provider = new KubernetesSeedProvider(new HashMap<String, String>());
|
SeedProvider provider = new KubernetesSeedProvider(new HashMap<String, String>());
|
||||||
List<InetAddress> seeds = provider.getSeeds();
|
List<InetAddress> seeds = provider.getSeeds();
|
||||||
|
|
||||||
assertThat(seeds, is(not(empty())));
|
assertThat(seeds, not(empty()));
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue