Add a package.json file for a better javascript development experience (#365)
* Add a package.json file for a better javascript development experience * remove publushing information from the package.json
This commit is contained in:
parent
d104477d64
commit
75b481e2dc
|
@ -123,10 +123,10 @@ jobs:
|
|||
node-version: '12.x'
|
||||
- name: Install Dependencies
|
||||
run: |
|
||||
npm install phantomjs-prebuilt@2.1.15 grunt-cli grunt grunt-contrib-qunit
|
||||
npm install
|
||||
- name: QUnit Tests
|
||||
run: |
|
||||
grunt test
|
||||
npm test
|
||||
env:
|
||||
CI: true
|
||||
publish:
|
||||
|
|
|
@ -32,8 +32,8 @@ it.
|
|||
|
||||
You can do this with `git commit --allow-empty`
|
||||
|
||||
Running Tests
|
||||
-------------
|
||||
Running Tests - Python
|
||||
----------------------
|
||||
|
||||
You will need `Tox <https://tox.readthedocs.io>`_ installed to run the tests
|
||||
against the supported Python versions. If you're using `Pipenv`_ it will be
|
||||
|
@ -52,18 +52,38 @@ Otherwise, to install and run, do:
|
|||
$ pip install tox
|
||||
$ tox
|
||||
|
||||
Running Tests - JavaScript
|
||||
--------------------------
|
||||
|
||||
You will need `npm <https://www.npmjs.com>`_ installed to run the JavaScript tests.
|
||||
Internally, we use `Grunt <https://gruntjs.com>`_ and `QUnit <https://qunitjs.com>`_ to run the tests.
|
||||
|
||||
Once ``npm`` is installed, you can install all needed dependencies by running:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ npm install
|
||||
|
||||
Run the following to execute the tests:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ npm test
|
||||
|
||||
Releasing a new version
|
||||
-----------------------
|
||||
|
||||
Follow these steps to release a new version of the project:
|
||||
|
||||
1. Update your local master with the upstream master (``git pull --rebase upstream master``)
|
||||
2. Create a new branch and update ``CHANGES.rst`` with the new version, today's date, and all changes/new features
|
||||
3. Commit and push the new branch and then create a new pull request
|
||||
4. Wait for tests and reviews and then merge the branch
|
||||
5. Once merged, update your local master again (``git pull --rebase upstream master``)
|
||||
6. Tag the release with the new release version (``git tag v<new tag>``)
|
||||
7. Push the tag (``git push upstream --tags``)
|
||||
8. Done. Check `CI <https://github.com/pytest-dev/pytest-html/actions>`_ for release progress.
|
||||
1. Update your local master with the upstream master (``git pull --rebase upstream master``)
|
||||
2. Create a new branch
|
||||
3. Update ``CHANGES.rst`` with the new version, today's date, and all changes/new features
|
||||
4. Update the ``version`` field in ``package.json`` with the new version
|
||||
5. Commit and push the new branch and then create a new pull request
|
||||
6. Wait for tests and reviews and then merge the branch
|
||||
7. Once merged, update your local master again (``git pull --rebase upstream master``)
|
||||
8. Tag the release with the new release version (``git tag v<new tag>``)
|
||||
9. Push the tag (``git push upstream --tags``)
|
||||
10. Done. Check `CI <https://github.com/pytest-dev/pytest-html/actions>`_ for release progress.
|
||||
|
||||
.. _Pipenv: https://pipenv.pypa.io/en/latest/
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
"main": "Gruntfile.js",
|
||||
"dependencies": {
|
||||
"grunt": "^1.3.0",
|
||||
"grunt-cli": "^1.3.2",
|
||||
"grunt-contrib-qunit": "^4.0.0",
|
||||
"phantomjs-prebuilt": "2.1.15"
|
||||
},
|
||||
"devDependencies": {},
|
||||
"scripts": {
|
||||
"test": "grunt test"
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue