{"action":"created","issue":{"url":"https://api.github.com/repos/marco-c/autowebcompat/issues/63","repository_url":"https://api.github.com/repos/marco-c/autowebcompat","labels_url":"https://api.github.com/repos/marco-c/autowebcompat/issues/63/labels{/name}","comments_url":"https://api.github.com/repos/marco-c/autowebcompat/issues/63/comments","events_url":"https://api.github.com/repos/marco-c/autowebcompat/issues/63/events","html_url":"https://github.com/marco-c/autowebcompat/pull/63","id":298024060,"number":63,"title":"[#5] Add unit tests for the functions in utils.py","user":{"login":"Shashi456","id":18056781,"avatar_url":"https://avatars1.githubusercontent.com/u/18056781?v=4","gravatar_id":"","url":"https://api.github.com/users/Shashi456","html_url":"https://github.com/Shashi456","followers_url":"https://api.github.com/users/Shashi456/followers","following_url":"https://api.github.com/users/Shashi456/following{/other_user}","gists_url":"https://api.github.com/users/Shashi456/gists{/gist_id}","starred_url":"https://api.github.com/users/Shashi456/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shashi456/subscriptions","organizations_url":"https://api.github.com/users/Shashi456/orgs","repos_url":"https://api.github.com/users/Shashi456/repos","events_url":"https://api.github.com/users/Shashi456/events{/privacy}","received_events_url":"https://api.github.com/users/Shashi456/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-17T18:07:28Z","updated_at":"2018-02-17T18:37:33Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/marco-c/autowebcompat/pulls/63","html_url":"https://github.com/marco-c/autowebcompat/pull/63","diff_url":"https://github.com/marco-c/autowebcompat/pull/63.diff","patch_url":"https://github.com/marco-c/autowebcompat/pull/63.patch"},"body":"These are just very basic unit tests , which is my understanding of them. Since we are just checking each module individually and seeing if they do the job they are supposed to do. Also another thing i wanted to ask is how could i go about writing tests for functions which had no parameters, should i just check the existence of what has been returned? Thanks for your help.\r\n\r\n@marco-c I will clean up the code and use tempfile in the upcoming commit, this was just for a basic check to see if you were expecting similar unit tests."},"comment":{"url":"https://api.github.com/repos/marco-c/autowebcompat/issues/comments/366462014","html_url":"https://github.com/marco-c/autowebcompat/pull/63#issuecomment-366462014","issue_url":"https://api.github.com/repos/marco-c/autowebcompat/issues/63","id":366462014,"user":{"login":"marco-c","id":1616846,"avatar_url":"https://avatars1.githubusercontent.com/u/1616846?v=4","gravatar_id":"","url":"https://api.github.com/users/marco-c","html_url":"https://github.com/marco-c","followers_url":"https://api.github.com/users/marco-c/followers","following_url":"https://api.github.com/users/marco-c/following{/other_user}","gists_url":"https://api.github.com/users/marco-c/gists{/gist_id}","starred_url":"https://api.github.com/users/marco-c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marco-c/subscriptions","organizations_url":"https://api.github.com/users/marco-c/orgs","repos_url":"https://api.github.com/users/marco-c/repos","events_url":"https://api.github.com/users/marco-c/events{/privacy}","received_events_url":"https://api.github.com/users/marco-c/received_events","type":"User","site_admin":false},"created_at":"2018-02-17T18:37:33Z","updated_at":"2018-02-17T18:37:33Z","author_association":"OWNER","body":">  Also another thing i wanted to ask is how could i go about writing tests for functions which had no parameters, should i just check the existence of what has been returned?\r\n\r\nFor functions that require the `data` directory to exist, don't write any test.\r\nFor other functions with no parameters (e.g. `get_bugs`), just make some basic assertion on the result."}}
{"actor":{"display_login":"marco-c"}}