This repository has been archived by the owner on Oct 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bug fixed for JSONScanner. issue #1001
- Loading branch information
Showing
2 changed files
with
25 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.alibaba.json.test; | ||
|
||
import com.alibaba.fastjson.JSON; | ||
import com.alibaba.fastjson.JSONReader; | ||
import junit.framework.TestCase; | ||
import org.apache.commons.io.FileUtils; | ||
|
||
import java.io.File; | ||
import java.io.StringReader; | ||
|
||
/** | ||
* Created by wenshao on 21/01/2017. | ||
*/ | ||
public class Issue1001 extends TestCase { | ||
public void test_for_issue() throws Exception { | ||
File file = new File("/Users/wenshao/Downloads/issue_1001.json"); | ||
|
||
String json = FileUtils.readFileToString(file); | ||
|
||
JSONReader reader = new JSONReader(new StringReader(json)); | ||
reader.readObject(); | ||
} | ||
} |