Skip to content
This repository was archived by the owner on Feb 6, 2024. It is now read-only.

Commit fe6226f

Browse files
committed
there is no ☁️
1 parent fac629c commit fe6226f

File tree

9 files changed

+30
-171
lines changed

9 files changed

+30
-171
lines changed

.travis.yml

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ install:
1111
- 'sudo pip install -r requirements.txt -UI'
1212

1313
script:
14-
# - '[ "${TRAVIS_PULL_REQUEST}" != "false" ] || nosetests -svx dronekit.test.web'
1514
- 'nosetests -svx dronekit.test.unit'
1615
- 'nosetests -svx dronekit.test.sitl'
1716

appveyor.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ install:
1515
[wheel]
1616
wheel-dir = c:/Users/appveyor/.pip-wheelhouse
1717
'@ | out-file -Encoding ascii -FilePath c:\Users\appveyor\pip\pip.ini
18-
18+
1919
- cmd: 'SET PATH=%PYTHON%;c:\\Python27\\Scripts;%PATH%'
2020
- cmd: 'SET PYTHONUNBUFFERED=1'
2121

@@ -24,7 +24,6 @@ install:
2424
- cmd: 'pip install -r requirements.txt -UI'
2525

2626
build_script:
27-
# - cmd: 'nosetests -svx dronekit.test.web'
2827
- cmd: 'nosetests -svx dronekit.test.unit'
2928
- cmd: 'nosetests -svx dronekit.test.sitl'
3029

circle.yml

-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ test:
1414
- 'cd docs; make clean; make html'
1515

1616
# code
17-
# - 'nosetests -svx dronekit.test.web'
1817
- 'nosetests -svx dronekit.test.unit'
1918
- 'nosetests -svx dronekit.test.sitl'
2019

docs/contributing/contributions_api.rst

+28-47
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,16 @@ Contributing to the API
66

77
This article provides a high level overview of how to contribute changes to the DroneKit-Python source code.
88

9-
.. tip::
9+
.. tip::
1010

11-
We highly recommend that changes and ideas are `discussed with the project team
12-
<https://github.com/dronekit/dronekit-python/issues>`_ before starting work!
11+
We highly recommend that changes and ideas are `discussed with the project team
12+
<https://github.com/dronekit/dronekit-python/issues>`_ before starting work!
1313

1414

1515
Submitting changes
1616
==================
1717

18-
Contributors should fork the main `dronekit/dronekit-python/ <https://github.com/dronekit/dronekit-python>`_
18+
Contributors should fork the main `dronekit/dronekit-python/ <https://github.com/dronekit/dronekit-python>`_
1919
repository and contribute changes back to the project master branch using pull requests
2020

2121
* Changes should be :ref:`tested locally <contributing-test-code>` before submission.
@@ -32,9 +32,8 @@ Test code
3232

3333
There are three test suites in DroneKit-Python:
3434

35-
* **Unit tests** (:file:`tests/unit`) — verify all code paths of the API.
35+
* **Unit tests** (:file:`tests/unit`) — verify all code paths of the API.
3636
* **Integration tests** (:file:`tests/sitl`) — verify real-world code, examples, and documentation as they would perform in a real environment.
37-
* **Web client tests** (:file:`tests/web`) — specifically verify the Python library's capability to talk to `DroneKit Cloud <http://cloud.dronekit.io>`_.
3837

3938
Test code should be used to verify new and changed functionality. New tests should:
4039

@@ -46,20 +45,20 @@ Test code should be used to verify new and changed functionality. New tests shou
4645
Setting up local testing
4746
------------------------
4847

49-
Follow the links below to set up a development environment on your Linux or Windows computer.
48+
Follow the links below to set up a development environment on your Linux or Windows computer.
5049

5150
* :ref:`dronekit_development_linux`
5251
* :ref:`dronekit_development_windows`
5352

54-
The tests require additional pip modules, including `nose <https://nose.readthedocs.org/en/latest/>`_, a
53+
The tests require additional pip modules, including `nose <https://nose.readthedocs.org/en/latest/>`_, a
5554
Python library and tool for writing and running test scripts. These can be installed separately using either of the commands below:
5655

5756
.. code:: bash
5857
5958
# Install just the additional requirements for tests
6059
pip install requests nose mock
6160
62-
# (or) Install all requirements for dronekit, tests, and building documentation
61+
# (or) Install all requirements for dronekit, tests, and building documentation
6362
pip install -r requirements.txt
6463
6564
For several tests, you may be required to set an **environment variable**. In your command line, you can set the name of a variable to equal a value using the following invocation, depending on your OS:
@@ -73,35 +72,35 @@ For several tests, you may be required to set an **environment variable**. In yo
7372
Unit tests
7473
----------
7574

76-
All new features should be created with accompanying unit tests.
75+
All new features should be created with accompanying unit tests.
7776

7877
DroneKit-Python unit tests are based on the `nose <https://nose.readthedocs.org/en/latest/>`_ test framework,
79-
and use `mock <https://docs.python.org/dev/library/unittest.mock.html>`_ to simulate objects and APIs and
78+
and use `mock <https://docs.python.org/dev/library/unittest.mock.html>`_ to simulate objects and APIs and
8079
ensure correct results.
8180

82-
To run the tests and display a summary of the results (on any OS),
83-
navigate to the **dronekit-python** folder and enter the following
81+
To run the tests and display a summary of the results (on any OS),
82+
navigate to the **dronekit-python** folder and enter the following
8483
command on a terminal/prompt:
8584

8685
.. code:: bash
8786
8887
nosetests dronekit.test.unit
89-
88+
9089
9190
9291
9392
Writing a new unit test
9493
^^^^^^^^^^^^^^^^^^^^^^^
9594

96-
Create any file named :file:`test_XXX.py` in the :file:`tests/unit` folder to add it as a test.
95+
Create any file named :file:`test_XXX.py` in the :file:`tests/unit` folder to add it as a test.
9796
Feel free to copy from existing tests to get started. When *nosetests* is run, it will add your new test to its summary.
9897

99-
Tests names should be named based on their associated Github issue (for example,
100-
``test_12.py`` for `issue #12 <https://github.com/dronekit/dronekit-python/issues/12>`_)
101-
or describe the functionality covered (for example, ``test_waypoints.py``
98+
Tests names should be named based on their associated Github issue (for example,
99+
``test_12.py`` for `issue #12 <https://github.com/dronekit/dronekit-python/issues/12>`_)
100+
or describe the functionality covered (for example, ``test_waypoints.py``
102101
for a unit test for the waypoints API).
103-
104-
Use assertions to test your code is consistent. You can use the built-in Python ``assert`` macro as well as ``assert_equals`` and ``assert_not_equals``
102+
103+
Use assertions to test your code is consistent. You can use the built-in Python ``assert`` macro as well as ``assert_equals`` and ``assert_not_equals``
105104
from the ``notestools`` module:
106105

107106
.. note::
@@ -116,7 +115,7 @@ from the ``notestools`` module:
116115
assert the_number_two > 0, '2 should be greater than zero!'
117116
assert_equals(the_number_two, 2, '2 should equal two!')
118117
assert_not_equals(the_number_two, 1, '2 should equal one!')
119-
118+
120119
Please add documentation to each test function describing what behavior it verifies.
121120

122121

@@ -129,8 +128,8 @@ Integrated tests use a custom test runner that is similar to *nosetests*. On any
129128
130129
cd dronekit-python
131130
nosetests dronekit.test.sitl
132-
133-
You can choose to run a specific tests. The example below shows how to run
131+
132+
You can choose to run a specific tests. The example below shows how to run
134133
**\dronekit-python\dronekit\test\sitl\test_12.py**.
135134

136135
.. code:: bash
@@ -160,12 +159,12 @@ Integration tests should be written or improved whenever:
160159

161160
You can write a new integrated test by adding (or copying) a file with the naming scheme :file:`test_XXX.py` to the :file:`tests/sitl` directory.
162161

163-
Tests names should be named based on their associated Github issue (for example,
164-
``test_12.py`` for `issue #12 <https://github.com/dronekit/dronekit-python/issues/12>`_)
165-
or describe the functionality covered (for example, ``test_waypoints.py``
162+
Tests names should be named based on their associated Github issue (for example,
163+
``test_12.py`` for `issue #12 <https://github.com/dronekit/dronekit-python/issues/12>`_)
164+
or describe the functionality covered (for example, ``test_waypoints.py``
166165
for an integration test for the waypoints API).
167166

168-
Tests should minimally use the imports shown below and decorate test functions with ``@with_sitl``
167+
Tests should minimally use the imports shown below and decorate test functions with ``@with_sitl``
169168
(this sets up the test and passes in a connection string for SITL).
170169

171170
.. code:: python
@@ -184,13 +183,13 @@ Tests should minimally use the imports shown below and decorate test functions w
184183
vehicle.close()
185184
186185
187-
Use assertions to test your code is consistent. You can use the built-in Python ``assert`` macro as well as ``assert_equals`` and ``assert_not_equals``
186+
Use assertions to test your code is consistent. You can use the built-in Python ``assert`` macro as well as ``assert_equals`` and ``assert_not_equals``
188187
from the ``testlib`` module:
189188

190189
.. note::
191190

192191
Avoiding printing any data from your test!
193-
192+
194193

195194

196195
.. code:: python
@@ -202,21 +201,3 @@ from the ``testlib`` module:
202201
assert_equals(the_number_two, 2, '2 should equal two!'
203202
204203
Please add documentation to each test function describing what behavior it verifies.
205-
206-
Web client tests
207-
----------------
208-
209-
.. warning::
210-
211-
The web client library is being rewritten. Please `discuss with the project team
212-
<https://github.com/dronekit/dronekit-python/issues>`_ if you intend to develop with or for the present version of the web client.
213-
214-
Web client tests use *nosetests*. To run these, you will need to sign up for API keys from `cloud.dronekit.io <https://cloud.dronekit.io/>`_.
215-
With these, export a variable named ``DRONEAPI_KEY`` with a value in the format ``<id>.<key>`` to your environment.
216-
217-
On any OS, enter the following command on a terminal/prompt to run the web-client tests (and display summary results):
218-
219-
.. code:: bash
220-
221-
cd dronekit-python
222-
nosetests tests/web

dronekit/cloud/CloudClient.py

-52
This file was deleted.

dronekit/cloud/__init__.py

-1
This file was deleted.

dronekit/test/web/__init__.py

-1
This file was deleted.

dronekit/test/web/cloud_client_test.py

-65
This file was deleted.

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@
2626
],
2727
license='apache',
2828
packages=[
29-
'dronekit', 'dronekit.cloud', 'dronekit.test'
29+
'dronekit', 'dronekit.test'
3030
],
3131
ext_modules=[])

0 commit comments

Comments
 (0)