Skip to content

Commit

Permalink
Update junit to v4.13 (#607) (#609)
Browse files Browse the repository at this point in the history
* Update junit to v4.13
* Fix deprecation warnings for junit.framework.Assert

Assert now lives in `org.junit` namespace

Signed-off-by: Felix Obermaier <felix.obermaier@netcologne.de>
  • Loading branch information
FObermaier authored Oct 6, 2020
1 parent a1d3ec3 commit 845e28f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@

package org.locationtech.jts.io.kml;

import junit.framework.Assert;
import junit.framework.TestCase;
import junit.textui.TestRunner;
import org.junit.Assert;
import org.locationtech.jts.geom.Geometry;
import org.locationtech.jts.geom.GeometryFactory;
import org.locationtech.jts.geom.PrecisionModel;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import java.util.Iterator;
import java.util.Map;

import org.junit.Assert;
import org.locationtech.jts.geom.Geometry;
import org.locationtech.jts.geom.GeometryCollection;
import org.locationtech.jts.geom.GeometryFactory;
Expand All @@ -29,16 +30,15 @@
import org.locationtech.jts.operation.buffer.validate.BufferResultValidator;
import org.locationtech.jts.util.StringUtil;

import junit.framework.Assert;


/**
* @version 1.7
*/
public class BufferValidator
public class BufferValidator
{


public static void main(String[] args) throws Exception {
Geometry g =
new WKTReader().read(
Expand Down Expand Up @@ -255,7 +255,7 @@ public void test() throws Exception {
if (getOriginal().getClass() == GeometryCollection.class) {
return;
}

Assert.assertTrue(
supplement("BufferResultValidator failure"),
BufferResultValidator.isValid(getOriginal(), bufferDistance, getBuffer()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@

package org.locationtech.jts.simplify;

import org.junit.Assert;
import org.locationtech.jts.geom.Geometry;
import org.locationtech.jts.io.WKTReader;

import junit.framework.Assert;


/**
* Runs various validation tests on a the results of a geometry operation
Expand Down Expand Up @@ -59,7 +58,7 @@ public boolean isAllTestsPassed()
* Tests if the result is valid.
* Throws an exception if result is not valid.
* This allows chaining multiple tests together.
*
*
* @throws Exception if the result is not valid.
*/
public void test()
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<junit-version>3.7</junit-version>
<junit-version>4.13</junit-version>
<jdom-version>2.0.6</jdom-version>
<jump.version>1.2</jump.version>
<json-simple-version>1.1.1</json-simple-version>
Expand Down

0 comments on commit 845e28f

Please sign in to comment.