{"id":18463854,"url":"https://github.com/smartive/cas-fee-testing-excercises","last_synced_at":"2026-03-09T02:30:56.034Z","repository":{"id":175298991,"uuid":"653524722","full_name":"smartive/cas-fee-testing-excercises","owner":"smartive","description":"Excercises for the topic \"testing\". This is complementary to the lecture in the CAS FEE OST.","archived":false,"fork":false,"pushed_at":"2024-06-25T18:17:56.000Z","size":108,"stargazers_count":0,"open_issues_count":0,"forks_count":3,"subscribers_count":8,"default_branch":"main","last_synced_at":"2026-02-19T11:17:20.238Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/smartive.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2023-06-14T08:13:37.000Z","updated_at":"2024-06-25T18:17:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"83fd20e9-b92f-4a18-84fe-d4f0c8d18e28","html_url":"https://github.com/smartive/cas-fee-testing-excercises","commit_stats":null,"previous_names":["smartive/cas-fee-testing-excercises"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/smartive/cas-fee-testing-excercises","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartive%2Fcas-fee-testing-excercises","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartive%2Fcas-fee-testing-excercises/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartive%2Fcas-fee-testing-excercises/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartive%2Fcas-fee-testing-excercises/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/smartive","download_url":"https://codeload.github.com/smartive/cas-fee-testing-excercises/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartive%2Fcas-fee-testing-excercises/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30280814,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-09T02:23:26.802Z","status":"ssl_error","status_checked_at":"2026-03-09T02:22:46.175Z","response_time":61,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":[],"created_at":"2024-11-06T09:08:09.858Z","updated_at":"2026-03-09T02:30:56.000Z","avatar_url":"https://github.com/smartive.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Testing Excercises CAS FEE\n\nCode testing is a critical part of software development that involves verifying that code works as expected. Testing can help catch bugs and errors early in the development process, which can save time and money in the long run.\n\nThere are several types of testing, including unit testing, integration testing, and end-to-end testing. Unit testing involves testing individual units or components of code in isolation from the rest of the system. Integration testing involves testing how different units of code work together. End-to-end testing involves testing the entire system from start to finish.\n\nTo write a unit test, you first need to identify the unit of code that you want to test. This could be a function, a class, or a module. You then create a test case that exercises the unit of code and checks that it produces the expected output for a given input.\n\nThe test case typically consists of three parts: the setup, the execution, and the assertion. In the setup phase, you create any necessary objects or data structures that the unit of code requires. In the execution phase, you call the unit of code with the input data. In the assertion phase, you check that the output produced by the unit of code matches the expected output.\n\nSuch an example in JavaScript/TypeScript could be:\n\n```js\nfunction add(a, b) {\n  return a + b;\n}\n\ntest('add should return the sum of two numbers', () =\u003e {\n  const result = add(2, 3);\n  expect(result).toBe(5);\n});\n```\n\nTesting can be done manually or automatically. Automated testing is typically preferred because it can be faster and more reliable than manual testing. Automated testing can be done using testing frameworks such as Jest or AVA.\n\n\n# Run the unit tests\n\n```bash\nnpm run test\n```\n\nor \n\n```bash\nnpm run test:watch\n```\n\n# Run the web tests\n\n```bash\nnpm run test:web\n\nor \n\nnpm run test:web:headed\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmartive%2Fcas-fee-testing-excercises","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsmartive%2Fcas-fee-testing-excercises","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmartive%2Fcas-fee-testing-excercises/lists"}