DEV Community


Posted on

Get information from json file and test on other's branch

In this lab4, the main part was dealing with JSON files and test other's features on my application.

First, in this lab, I almost gave up while I am solving the issue to adding JSON feature to My partner's repo. When I parse JSON files to JS, I used Jquery and ajax. And both of them had the same error. The error message was a syntax error about a string that did not match the path. lab4 (2)

Hence, it took me two days to research and asked help from friends to ask about ways to solve error . However, no one can solve the problem and even I researched some ways on google, it does not work or applied to my code. So, I need to find another way to parse the JSON and I found one npm module called "JSON file". That npm module saved me from the give-up to finish this lab. After I solved that parse problem, the other parts went smoothly.

And the second part of this lab was reviewing and testing via remotes of my partner's pull request. She raised an issue about to add JSON feature which is the same feature as mine. I was a bit confused about the instruction to do run tests via remotes. Hence, I just reviewed the lecture again and follow what he did in the lecture. Fetch partner's repository and create a branch to test what she edited. However, there was some problem. There were 3 parts that she need to work on before I merge them into my repository.
These are three parts

1. It doesn't allow to accept the output option.
2. It doesn't ignore other options which are not available.
3. If the config file is missing any options, it does not have a default value specified.
Enter fullscreen mode Exit fullscreen mode

Hence, I leave a comment to the the partner's pull request.

In this lab, I learn how to run other's repositories without affecting my code. I think this feature is really great. This is because, in the first few labs, I wanted to use this feature. I want to edit some codes on my repository while my partner was working on the repository. I am just worried if it can cause a problem in merging the branch to my master branch. And for next time, if an error keeps having trouble for more than one day, I will also try to find a new way to write the same logic, not just google a way to fix the error.

Top comments (0)