Issue 91 in json-simple: MAVEN, json-simple 1.1.1 depends on Junit

149 views
Skip to first unread message

json-...@googlecode.com

unread,
Sep 23, 2013, 10:15:23 AM9/23/13
to json-...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 91 by colin...@gmail.com: MAVEN, json-simple 1.1.1 depends on
Junit
http://code.google.com/p/json-simple/issues/detail?id=91

What steps will reproduce the problem?
On central maven repo,
http://mvnrepository.com/artifact/com.googlecode.json-simple/json-simple/1.1.1
json-simple pom reference junit in its dependencies.

What is the expected output? What do you see instead?
junit deps should be in test scope

What version of the product are you using? On what operating system?
1.1.1

Please provide any additional information below.
json-simple comes with junit wich leads to conflicts in maven projects
using json-simple

Thanks


--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

json-...@googlecode.com

unread,
Feb 10, 2014, 5:09:58 PM2/10/14
to json-...@googlegroups.com

Comment #1 on issue 91 by xcolw...@gmail.com: MAVEN, json-simple 1.1.1
This is a one line fix, as the reporter has noted:

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.10</version>
<!-- FIXME --> <scope>test</scope>
</dependency>

There is no reason to include junit as a runtime dependency. It also throws
off the Android linker. To work around, you can use exclusions in your
project's POM:

<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
<version>1.1.1</version>
<exclusions>
<exclusion>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</exclusion>
<!-- maven note: must manually exclude all ancestors
see
http://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html
-->
<exclusion>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-core</artifactId>
</exclusion>
</exclusions>
</dependency>

json-...@googlecode.com

unread,
Mar 13, 2014, 9:50:28 AM3/13/14
to json-...@googlegroups.com

Comment #2 on issue 91 by mart...@gmail.com: MAVEN, json-simple 1.1.1
Hi problem is the same with Ivy
Dependency must be like :

<dependencies>
<dependency org="junit" name="junit" rev="4.10" force="true"
conf="test->runtime(*),master(*)"/>
</dependencies>

json-...@googlecode.com

unread,
May 11, 2014, 4:49:55 AM5/11/14
to json-...@googlegroups.com

Comment #3 on issue 91 by aheritier: MAVEN, json-simple 1.1.1 depends on
Junit
http://code.google.com/p/json-simple/issues/detail?id=91

Could you try to fix that little issue soon, perhaps in a 1.1.2 version ?
It is annoying for your users.

json-...@googlecode.com

unread,
Jul 30, 2015, 5:46:35 PM7/30/15
to json-...@googlegroups.com

Comment #4 on issue 91 by hemisf...@gmail.com: MAVEN, json-simple 1.1.1
depends on Junit
https://code.google.com/p/json-simple/issues/detail?id=91

annoying++

For android builds using gradle:

compile group: 'com.googlecode.json-simple', name: 'json-simple',
version: '1.1.1', transitive: false
Reply all
Reply to author
Forward
0 new messages