Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds the test cases for the Lau-Nuts API #6

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

vikrantsingh29
Copy link
Collaborator

  • Creates the test cases for the JSON response.
  • Creates the test cases for turtle response.

String content = EntityUtils.toString(entity);
JSONArray jsonArray = new JSONArray(content);

for (int i = 0; i < jsonArray.length(); i++) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please skip the for loop, we need only one object. Instead, just get the first element as follows:

JSONObject jsonobject = jsonArray.getJSONObject(0);

Same for all for loops....

Assert.assertEquals(arrays,
coordinatesGot);
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you also test the polygon coordinates of TTL response?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants