22 Commits

Author SHA1 Message Date
Erik Montnemery
46f92b2650
Update section about lint errors (#1219) 2022-02-19 12:21:39 +01:00
Erik Montnemery
a3cf4fca9b
Add legacy-resolver option to manual pip (#1218) 2022-02-19 12:20:52 +01:00
David Roberts
222b9d7175
Update testing code samples for python 3.9 (#1185) 2022-01-16 14:59:47 +01:00
Paulus Schoutsen
42b0196253
Optimize dev env instructions (#1072)
* Optimize dev env instructions

* Apply suggestions from code review

Co-authored-by: Tom Brien <TomBrien@users.noreply.github.com>

* Update extensions in others

* Typo

Co-authored-by: Tom Brien <TomBrien@users.noreply.github.com>
Co-authored-by: Tom Brien <tom@byth.co.uk>
2021-10-19 12:07:51 +01:00
karliemeads
3254b8359d
Change py.test -> pytest (#893) 2021-04-21 23:03:55 +02:00
Philip Allgaier
38a2908528
Note about PR and tox requirements (#772)
* Note about PR and tox requirements

As confirmed by Paulus: https://discord.com/channels/330944238910963714/330990195199442944/798321546673389618

* Update docs/development_testing.md

Co-authored-by: Tom Brien <TomBrien@users.noreply.github.com>

Co-authored-by: Tom Brien <TomBrien@users.noreply.github.com>
2021-03-16 18:53:33 +01:00
Jean-Paul van Ravensberg
3213be0db1
Add codecov command to dev instructions (#711)
* Add codecov command

* Process review feedback
2020-11-02 01:47:26 +01:00
Sam Welek
e47096e7d5
Fixes some Typos in the Documentation (#678)
* Fixing typo on development_enviornment.md

* Fixing various typos throughout the docs, it's not much but it's honest work
2020-10-11 15:47:52 +01:00
Martin Hjelmare
fef5353496
Add how to write tests for integrations (#654) 2020-09-30 16:43:33 +02:00
Franck Nijhof
08884e2cca
Collection of fixes and improvements (#516) 2020-05-11 08:12:01 -07:00
Ville Skyttä
770185004b
Code block improvements (#382)
* Use f-strings instead of .format()

* Code block language marker fixes

* Make example code blocks syntactically valid Python

* Run all python code blocks through black

https://github.com/scop/misc/blob/master/black_markdown.py

* Add some missing code block language markers

* Use shell language consistently to mark shell code blocks

* Undo folding of some example dicts

* Remove outdated OrderedDict comments per Python 3.7, replace with plain dict
2020-01-13 21:55:41 +02:00
Michaël Arnauts
fd0e9d5e0b Fix typo in development_testing.md (#360) 2019-11-25 08:52:32 -08:00
Fabian Affolter
f55f7e680a Add requirements on OS level for Fedora and Ubuntu (#350) 2019-11-01 20:09:56 -07:00
Sean Mooney
7984f941e5 Update development_testing.md (#277) 2019-06-20 08:36:32 -07:00
pp81381
359b6334b3 Update development_testing.md (#249)
I found that in the absence of the package constraints, the pip3 install command in the testing outside of tox section caused problems.
2019-05-06 09:49:09 +02:00
Neil Crosby
62b585644d Use tox-venv to allow tests to run on OSX (#131)
Installing `tox-venv` on OSX allows `tox` tests to be run, per https://community.home-assistant.io/t/installing-hass-on-macos-osx/69292

Alternatively, `tox-venv` _could_ be added directly into the https://github.com/home-assistant/home-assistant/blob/dev/script/bootstrap file, but since nobody outside of OSX developers seem to be having this problem it seemed safer to simply note it in the documentation.

Without installing `tox-venv` the following occurs:

    ERROR: invocation failed (exit code 100), logfile: /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37/log/py37-0.log
    ERROR: actionid: py37
    msg: getenv
    cmdargs: '/Users/neilcrosby/Documents/git-projects.nosync/home-assistant/bin/python3 -m virtualenv --python /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/bin/python3 py37'
    
    /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/lib/python3.7/site-packages/virtualenv.py:1041: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
      import imp
    Already using interpreter /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/bin/python3
    Using base prefix '/usr/local/bin/../Cellar/python/3.7.0/bin/../Frameworks/Python.framework/Versions/3.7'
    New python executable in /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37/bin/python3
    Also creating executable in /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37/bin/python
    ERROR: The executable /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37/bin/python3 is not functioning
    ERROR: It thinks sys.prefix is '/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7' (should be '/Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37')
    ERROR: virtualenv is not compatible with this system or executable
    
    ERROR: Error creating virtualenv. Note that some special characters (e.g. ':' and unicode symbols) in paths are not supported by virtualenv. Error details: InvocationError('/Users/neilcrosby/Documents/git-projects.nosync/home-assistant/bin/python3 -m virtualenv --python /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/bin/python3 py37 (see /Users/neilcrosby/Documents/git-projects.nosync/home-assistant/.tox/py37/log/py37-0.log)', 100)
2018-10-23 21:45:34 +02:00
Robert Svensson
d9462eb621 Simplify locating how to add dependencies to test environment (#122) 2018-10-10 22:20:09 +02:00
David De Sloovere
53d3ed9fa1 Add virtual environment info to testing (tox) doc (#98)
* Update testing info with virtual environment

Being new to python, pip and virtual environments, I tried running `tox` without activating the virtual environment. This should make it a little bit more clear for newcomers.

* Update development_testing.md

* Update development_testing.md

* Update development_testing.md
2018-10-01 15:28:41 +02:00
Paulus Schoutsen
2fd443fe2c fix broken links 2018-04-25 14:19:41 -04:00
Paulus Schoutsen
9311326aec Remove unused header 2018-04-24 15:44:32 -04:00
Paulus Schoutsen
632bc81a20 Fix all headers 2018-04-24 11:46:45 -04:00
Paulus Schoutsen
746e35b7a7 Migrate to Docusaurus 2018-04-24 09:52:18 -04:00