Skip to content

Commit a25ebf8

Browse files
committed
chore: add dev workflow and github templates
1 parent c133b81 commit a25ebf8

File tree

4 files changed

+202
-0
lines changed

4 files changed

+202
-0
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
name: Bug report
3+
about: 'We really appreciate your effort to provide feedback. Before opening a new
4+
issue, please make sure that this case is not already reported in GitHub as an
5+
issue or in StackOverflow as a question.'
6+
7+
---
8+
9+
**Environment**
10+
Provide version numbers for the following components (information can be retrieved by running `tns info` in your project folder or by inspecting the `package.json` of the project):
11+
- CLI:
12+
- Cross-platform modules:
13+
- Android Runtime:
14+
- iOS Runtime:
15+
- Plugin(s):
16+
- NativeScript-Angular:
17+
- Angular:
18+
19+
**Describe the bug**
20+
<!-- A clear and concise description of what the bug is. Please, explain whether it's a build time error or a runtime error. More detailed logs can be easily obtained by following the instructions in this guide: https://docs.nativescript.org/get-support#how-to-obtain-diagnostic-reports. -->
21+
22+
**To Reproduce**
23+
<!-- Add commands used or steps taken to reproduce the behaviour. -->
24+
25+
**Expected behavior**
26+
27+
**Sample project**
28+
<!-- If possible, provide a link from the [Playground](https://play.nativescript.org) with reproduction of the problem. If not, consider attaching a sample project or link to a repository with such project. -->
29+
30+
**Additional context**
31+
<!-- Add any other context about the problem here. -->
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
5+
---
6+
7+
**Is your feature request related to a problem? Please describe.**
8+
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]. -->
9+
10+
**Describe the solution you'd like**
11+
<!-- A clear and concise description of what you want to happen. -->
12+
13+
**Describe alternatives you've considered**
14+
<!-- A clear and concise description of any alternative solutions or features you've considered. -->
15+
16+
**Additional context**
17+
<!-- Add any other context or screenshots about the feature request here. -->

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
<!--
2+
We, the rest of the NativeScript community, thank you for your
3+
contribution!
4+
To help the rest of the community review your change, please follow the instructions in the template.
5+
-->
6+
7+
<!-- PULL REQUEST TEMPLATE -->
8+
<!-- (Update "[ ]" to "[x]" to check a box) -->
9+
10+
## PR Checklist
11+
12+
- [ ] The PR title follows our guidelines: https://github.com/NativeScript/NativeScript/blob/master/CONTRIBUTING.md#commit-messages.
13+
- [ ] There is an issue for the bug/feature this PR is for. To avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it.
14+
- [ ] You have signed the [CLA](http://www.nativescript.org/cla).
15+
- [ ] All existing tests are passing: https://github.com/NativeScript/angular/blob/master/DevelopmentWorkflow.md#running-the-tests
16+
- [ ] Tests for the changes are included.
17+
18+
## What is the current behavior?
19+
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->
20+
21+
## What is the new behavior?
22+
<!-- Describe the changes. -->
23+
24+
Fixes/Implements/Closes #[Issue Number].
25+
26+
<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. -->
27+
28+
<!--
29+
BREAKING CHANGES:
30+
31+
32+
[Describe the impact of the changes here.]
33+
34+
Migration steps:
35+
[Provide a migration path for existing applications.]
36+
-->
37+

DevelopmentWorkflow.md

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
# Development Workflow
2+
3+
<!-- TOC depthFrom:2 -->
4+
5+
- [Development Workflow](#development-workflow)
6+
- [Running locally](#running-locally)
7+
- [Prerequisites](#prerequisites)
8+
- [Clone repository](#clone-repository)
9+
- [Install dependencies](#install-dependencies)
10+
- [Run some of the e2e applications e.g. router-tab-view](#run-some-of-the-e2e-applications-eg-router-tab-view)
11+
- [Running the tests](#running-the-tests)
12+
- [Testing locally by running e2e tests](#testing-locally-by-running-e2e-tests)
13+
- [Building Packages](#building-packages)
14+
15+
<!-- /TOC -->
16+
17+
## Running locally
18+
19+
### Prerequisites
20+
21+
Install your native toolchain and NativeScript as described in the docs:
22+
23+
https://docs.nativescript.org/environment-setup.html
24+
25+
### Clone repository
26+
27+
```
28+
$ git clone git@github.com:NativeScript/angular.git
29+
$ cd angular
30+
```
31+
32+
### Install dependencies
33+
34+
```
35+
$ cd angular
36+
$ npm clean.all
37+
```
38+
39+
### Run some of the e2e applications e.g. router-tab-view
40+
41+
**E2E TESTS STILL NOT IN THIS REPO!** instead use `apps/nativescript-demo-ng`
42+
43+
Install NPM packages (use the local copy of `@nativescript/angular`):
44+
```
45+
$ cd e2e/router-tab-view
46+
$ npm install
47+
```
48+
49+
Start the app:
50+
51+
```
52+
$ tns run android
53+
$ tns run ios
54+
```
55+
56+
Make changes to `@nativescript/angular` and see them applied in the running app.
57+
58+
## Running the tests
59+
60+
Install the NPM dependencies:
61+
```
62+
$ cd apps/nativescript-demo-ng
63+
$ npm install
64+
```
65+
66+
Run the tests:
67+
68+
```
69+
$ ns test ios
70+
$ ns test android
71+
```
72+
73+
## Testing locally by running e2e tests
74+
75+
**E2E TESTS STILL NOT IN THIS REPO!**
76+
77+
NOTE: The steps below describe how to run `renderer` tests, but the same approach can be used to run `router` or any other `e2e` tests.
78+
79+
1. Navigate to `e2e/renderer`
80+
``` bash
81+
cd e2e/renderer
82+
```
83+
84+
2. Install dependencies. This also installs your local copy of the nativescript-angular plugin.
85+
``` bash
86+
npm install
87+
```
88+
3. Make sure to have an emulator set up or connect a physical Android/iOS device.
89+
90+
4. Build the app for Android or iOS
91+
```bash
92+
tns run android/ios
93+
```
94+
95+
5. Install [appium](http://appium.io/) globally.
96+
``` bash
97+
npm install -g appium
98+
```
99+
100+
6. Follow the instructions in the [nativescript-dev-appium](https://github.com/nativescript/nativescript-dev-appium#custom-appium-capabilities) plugin to add an appium capability for your device inside `./e2e/renderer/e2e/config/appium.capabilities.json`.
101+
102+
7. Run the automated tests. The value of the `runType` argument should match the name of the capability that you just added.
103+
``` bash
104+
npm run e2e -- --runType capabilityName
105+
```
106+
107+
## Building Packages
108+
109+
1. Build `@nativescript/angular`:
110+
```
111+
npx nx run angular:build
112+
```
113+
2. Build `@nativescript/zone-js`
114+
```
115+
npx nx run zone-js:build
116+
```
117+
Packages are available in the `dist` folder.

0 commit comments

Comments
 (0)