{"id":17148813,"url":"https://github.com/trustmaster/cot-testing","last_synced_at":"2025-03-24T11:41:14.785Z","repository":{"id":2785625,"uuid":"3785340","full_name":"trustmaster/cot-testing","owner":"trustmaster","description":"Unit testing module for Cotonti CMS/CMF","archived":false,"fork":false,"pushed_at":"2012-07-26T08:45:16.000Z","size":104,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-29T16:44:12.581Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://www.cotonti.com/extensions/development-maintenance/testing_module","language":"PHP","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/trustmaster.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}},"created_at":"2012-03-21T10:08:03.000Z","updated_at":"2013-12-19T18:29:40.000Z","dependencies_parsed_at":"2022-07-13T00:31:07.040Z","dependency_job_id":null,"html_url":"https://github.com/trustmaster/cot-testing","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trustmaster%2Fcot-testing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trustmaster%2Fcot-testing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trustmaster%2Fcot-testing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trustmaster%2Fcot-testing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/trustmaster","download_url":"https://codeload.github.com/trustmaster/cot-testing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245265905,"owners_count":20587411,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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-10-14T21:29:54.567Z","updated_at":"2025-03-24T11:41:14.761Z","avatar_url":"https://github.com/trustmaster.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Unit testing module for Cotonti\n\nThis module automates execution of unit tests which can be bundled with Cotonti core and extensions.\n\n## Installation\n\n1. Download this repository as .zip or .tar.gz file and unpack it to some folder.\n2. Copy \"testing\" folder to you Cotonti modules directory.\n3. Go to Administration / Extensions and install the module.\n\n## Getting started\n\nInstructions on testing and writing tests are given on the module page itself.\nOpen it in your browser via http://example.com/index.php?e=testing or http://example.com/testing (depending on your URL settings).\n\nFor example, if you develop a module called 'myext', you can create a test file called 'myext/test/myext.test.php' and put a following function in it:\n\n```php\n// Include functions from your module\nrequire_once cot_incfile('myext', 'module');\n\n// This function tests myext_foo()\n// you can do multiple tests in a single function or file\nfunction test_myext_foo()\n{\n\t$res = myext_foo('bar');\n\tif ($res === 'baz')\n\t{\n\t\treturn true;\n\t}\n\telse\n\t{\n\t\treturn 'myext_foo() returned ' . $res;\n\t}\n}\n```\n\nThen you can open testing module and run tests for this particular extension or entire site at once.\n\nFor more information please visit [module page at Cotonti Extensions](http://www.cotonti.com/extensions/development-maintenance/testing_module)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrustmaster%2Fcot-testing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrustmaster%2Fcot-testing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrustmaster%2Fcot-testing/lists"}