{"id":15292291,"url":"https://github.com/themeplate/tester","last_synced_at":"2026-02-18T00:04:05.149Z","repository":{"id":37450050,"uuid":"492443476","full_name":"ThemePlate/Tester","owner":"ThemePlate","description":"Common for all packages","archived":false,"fork":false,"pushed_at":"2025-04-14T14:09:33.000Z","size":71,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-13T01:46:58.292Z","etag":null,"topics":["wordpress","wordpress-development","wordpress-tests"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"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/ThemePlate.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":"2022-05-15T09:36:50.000Z","updated_at":"2025-04-14T14:09:37.000Z","dependencies_parsed_at":"2025-04-08T06:23:56.704Z","dependency_job_id":"bd4e3d77-f653-4b31-952f-e41db982350d","html_url":"https://github.com/ThemePlate/Tester","commit_stats":{"total_commits":61,"total_committers":1,"mean_commits":61.0,"dds":0.0,"last_synced_commit":"e7c2f326c6d236569b2c1d66d373679e6e21446a"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/ThemePlate/Tester","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThemePlate%2FTester","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThemePlate%2FTester/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThemePlate%2FTester/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThemePlate%2FTester/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ThemePlate","download_url":"https://codeload.github.com/ThemePlate/Tester/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThemePlate%2FTester/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264292952,"owners_count":23586063,"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":["wordpress","wordpress-development","wordpress-tests"],"created_at":"2024-09-30T16:17:17.185Z","updated_at":"2026-02-18T00:04:05.110Z","avatar_url":"https://github.com/ThemePlate.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ThemePlate Tester\n\n#### Available commands:\n| Name    | Description       |\n|---------|-------------------|\n| analyse | Analyse the codes |\n| dump    | Dump the configs  |\n| fix     | Fix the codes     |\n| lint    | Lint the codes    |\n| setup   | Setup the tests   |\n| test    | Run the tests     |\n\n## Usage\n\n### composer.json\n```json\n{\n\t\"name\": \"my/package\",\n\t\"require\": {\n\t\t\"php\": \"^7.4|^8.2\"\n\t},\n\t\"require-dev\": {\n\t\t\"themeplate/tester\": \"*\"\n\t},\n\t\"autoload-dev\": {\n\t\t\"psr-4\": {\n\t\t\t\"Tests\\\\\": \"tests\"\n\t\t}\n\t}\n}\n```\n\n### SampleTest.php\n```php\nnamespace Tests;\n\nuse ThemePlate\\Tester\\Utils;\n\nclass SampleTest extends WP_UnitTestCase {\n\tpublic function test_sample() {\n\t\t$instance = new Class();\n\n\t\tUtils::invoke_inaccessible_method( $instance, 'method_name', array( 'arg1', 'arg2' ) );\n\n\t\t$value = Utils::get_inaccessible_property( $instance, 'property_name' );\n\n\t\tUtils::set_inaccessible_property( $instance, 'wanted_property', $value );\n\n\t\t// Do actual assertions\n\t}\n}\n```\n\n### After `composer install`, run `./vendor/bin/themeplate setup`\n- Analyse `./vendor/bin/themeplate analyse`\n- Lint `./vendor/bin/themeplate lint`\n- Fix `./vendor/bin/themeplate fix`\n- Test `./vendor/bin/themeplate test`\n\n#### Dump the configs for customizations `./vendor/bin/themeplate dump`\n\n#### Sample composer scripts\n```json\n...\n    \"scripts\": {\n        \"analyse\": \"themeplate analyse\",\n        \"lint\": \"themeplate lint\",\n        \"fix\": \"themeplate fix\",\n        \"test\": \"themeplate test\",\n        \"test:unit\": \"themeplate test --type unit\",\n        \"test:integration\": \"themeplate test --type integration\"\n    }\n...\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthemeplate%2Ftester","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthemeplate%2Ftester","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthemeplate%2Ftester/lists"}