{"id":20442884,"url":"https://github.com/mrbrunelli/tdd-node-jest","last_synced_at":"2026-04-18T07:36:19.344Z","repository":{"id":122802917,"uuid":"292384445","full_name":"mrbrunelli/tdd-node-jest","owner":"mrbrunelli","description":"My studies of test driven development (TDD) with Node.js","archived":false,"fork":false,"pushed_at":"2020-09-02T20:20:17.000Z","size":1520,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-08T15:43:44.854Z","etag":null,"topics":["jest","node","tdd"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mrbrunelli.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-09-02T20:11:38.000Z","updated_at":"2020-09-02T20:20:19.000Z","dependencies_parsed_at":null,"dependency_job_id":"72fc5d46-400b-495e-8c7f-c3943d75ec9a","html_url":"https://github.com/mrbrunelli/tdd-node-jest","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mrbrunelli/tdd-node-jest","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrbrunelli%2Ftdd-node-jest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrbrunelli%2Ftdd-node-jest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrbrunelli%2Ftdd-node-jest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrbrunelli%2Ftdd-node-jest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mrbrunelli","download_url":"https://codeload.github.com/mrbrunelli/tdd-node-jest/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrbrunelli%2Ftdd-node-jest/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31961347,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T00:39:45.007Z","status":"online","status_checked_at":"2026-04-18T02:00:07.018Z","response_time":103,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["jest","node","tdd"],"created_at":"2024-11-15T09:43:20.849Z","updated_at":"2026-04-18T07:36:19.327Z","avatar_url":"https://github.com/mrbrunelli.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## :heavy_check_mark: TDD Node + Jest\n\u003e My studies of Test-driven development with Node.js\n\n### Requisits\n- [x] Node\n- [x] Npm\n- [x] Jest\n- [x] Axios\n\n### To execute\n\u003e First install the dependencies\n```bash\nnpm install\n```\n\u003e Later, execute npm test\n```bash\nnpm test\n```\n\u003e For coverage details\n```bash\nnpx jest --coverage\n```\n\n![](./.github/terminal.png)\n\n### Easy to test features\n```javascript\nconst BranchController = require('./branch')\n\nconst makeSut = (url) =\u003e {\n  const sut = new BranchController(url)\n  return sut.handle(url)\n}\n\ndescribe('Branch Controller', () =\u003e {\n  test('Should return 200 if connect in /filial', async () =\u003e {\n    const statusCode = await makeSut('/api/filial')\n    expect(statusCode).toBe(200)\n  })\n\n  test('Should return 500 if provided incorrectly route', async () =\u003e {\n    const statusCode = await makeSut('invalid_route')\n    expect(statusCode).toBe(500)\n  })\n})\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrbrunelli%2Ftdd-node-jest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmrbrunelli%2Ftdd-node-jest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrbrunelli%2Ftdd-node-jest/lists"}