{"id":17226828,"url":"https://github.com/dantleech/vim-phpunit","last_synced_at":"2025-03-25T17:48:20.684Z","repository":{"id":31753796,"uuid":"35319935","full_name":"dantleech/vim-phpunit","owner":"dantleech","description":"Generate PHPUnit test cases with composer and reflaction","archived":false,"fork":false,"pushed_at":"2015-11-26T13:17:20.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-30T15:44:23.282Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/dantleech.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":"2015-05-09T07:36:52.000Z","updated_at":"2015-05-09T07:37:06.000Z","dependencies_parsed_at":"2022-09-10T09:30:28.478Z","dependency_job_id":null,"html_url":"https://github.com/dantleech/vim-phpunit","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/dantleech%2Fvim-phpunit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dantleech%2Fvim-phpunit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dantleech%2Fvim-phpunit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dantleech%2Fvim-phpunit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dantleech","download_url":"https://codeload.github.com/dantleech/vim-phpunit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245515074,"owners_count":20628101,"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-15T04:17:20.403Z","updated_at":"2025-03-25T17:48:20.659Z","avatar_url":"https://github.com/dantleech.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"vim-phpunit\n===========\n\nGenerates and opens an empty (or the existing) PHPUnit test case for the\ncurrent class using Reflection and `composer.json`.\n\nFor example, if your file's namespace is `namespace MyProject\\Bar\\Doo` and\ncomposer autoload is configured with `{\"MyProject\\\\\": \"foo/\"}` then the test\nnamespace will be `namespace MyProject\\Tests\\Bar\\Doo` and the test will\ncreated at `foo/Tests/Bar/DooTest.php`\n\nIf you have defined a specific location for tests in your `composer.json` then\nthat path will be used, for example:\n\n````php\n{\n    \"autoload\": {\n        \"psr-4\": {\n            \"MyProject\\\\\": \"src/\"\n        }\n    },\n    \"autoload-dev\": {\n        \"psr-4\": {\n            \"MyProject\\\\Tests\\\\\": \"tests/\"\n        }\n    }\n}\n````\n\nThe generated test namespace will match the `autoload-dev` entry, and the test\nwill be created at `tests/Bar/DooTest.php`.\n\nInstallation\n------------\n\nUsing vundle:\n\n````vim\nPlugin 'dantleech/vim-phpunit'\n````\n\nConfiguration\n-------------\n\nBy default it will prefix the sub-namespace with `Tests`, this can be\noverridden as follows:\n\n````vim\nlet g:phpunit_namespace_prefix=\"Tests\\\\Unit\"\n````\n\nYou can also chane the path to phpunit:\n\n````vim\nlet g:phpunitpath=\"/usr/local/bin/phpunit\"\n````\n\nMapping:\n\n````vim\nnnoremap \u003csilent\u003e\u003cleader\u003ept :call PhpunitGenerate()\u003cCR\u003e\nnnoremap \u003csilent\u003e\u003cleader\u003epp :call PhpunitRun()\u003cCR\u003e\n````\n\nNotes\n-----\n\n- Currently only works with `psr-4`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdantleech%2Fvim-phpunit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdantleech%2Fvim-phpunit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdantleech%2Fvim-phpunit/lists"}