{"id":16432045,"url":"https://github.com/juandelgadillo/nativescript-tests-hook","last_synced_at":"2025-10-27T01:30:49.805Z","repository":{"id":57308790,"uuid":"77267999","full_name":"JuanDelgadillo/nativescript-tests-hook","owner":"JuanDelgadillo","description":"Nativescript plugin that lets you handling your Nativescript tests like the angular style guide","archived":false,"fork":false,"pushed_at":"2019-02-21T03:56:54.000Z","size":2,"stargazers_count":2,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-01T01:26:13.801Z","etag":null,"topics":["nativescript-plugin","nativescript-tests"],"latest_commit_sha":null,"homepage":null,"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/JuanDelgadillo.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":"2016-12-24T05:41:07.000Z","updated_at":"2018-03-15T18:24:03.000Z","dependencies_parsed_at":"2022-08-29T06:50:53.274Z","dependency_job_id":null,"html_url":"https://github.com/JuanDelgadillo/nativescript-tests-hook","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/JuanDelgadillo%2Fnativescript-tests-hook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanDelgadillo%2Fnativescript-tests-hook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanDelgadillo%2Fnativescript-tests-hook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuanDelgadillo%2Fnativescript-tests-hook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JuanDelgadillo","download_url":"https://codeload.github.com/JuanDelgadillo/nativescript-tests-hook/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238418238,"owners_count":19468869,"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":["nativescript-plugin","nativescript-tests"],"created_at":"2024-10-11T08:42:37.638Z","updated_at":"2025-10-27T01:30:44.542Z","avatar_url":"https://github.com/JuanDelgadillo.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nativescript tests hook\nNativescript plugin that lets you handling your Nativescript tests like the angular style guide\n\nNativescript is configured by default to let you put all your tests into `tests` folder but sometimes it can be a little annoying, as apps grow in size and components, having unit-tests next to implementations makes easier maintaining these tests, when we do development for web version of angular application, we put the test files in respective feature folders with `.spec.ts` or `.spec.js` suffix as per the angular style guide.\n\n### Example\n~~~\napp\n|-- myFeature\n     |- myFeature.component.html\n     |- myFeature.component.ts\n     |- myFeature.component.spec.ts\n~~~\n\nJust keep your `.spec.ts` or `.spec.js` files next to implementations and that's it. It moves all your tests from wherever they are into `app` to `tests` folder at tns' before-prepare hook time.\n\n## Installation\n\n### Npm\n\n```bash\nnpm install nativescript-tests-hook --save-dev\n```\n\n## Configuration\n\nThe only thing you need to be aware of is when importing file dependencies in your tests you have to reference them as loading files from the app bundle according to [Nativescript's Location Rules Docs](https://docs.nativescript.org/runtimes/require#loading-files-from-the-app-bundle) to keep their references when they will move.\n\n### Example\n\n```typescript\nimport { MyFeatureComponent } from '~/myFeature/myFeature.component';\nimport { AppComponent } from '~/app.component';\n\n\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuandelgadillo%2Fnativescript-tests-hook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjuandelgadillo%2Fnativescript-tests-hook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuandelgadillo%2Fnativescript-tests-hook/lists"}