Matthias Urlichs
5d8535cb9c
Test string must be Unicode
2019-01-28 14:14:23 +01:00
Matthias Urlichs
008cde6ef6
octoprint.user => octoprint.access.user
2019-01-28 14:14:23 +01:00
Matthias Urlichs
4df57cd8fe
Fix DeprecationWarning about using __plugin_implementations__
2019-01-28 14:14:23 +01:00
Matthias Urlichs
abfffa3231
Remove deprecated unittest.TestCase.assertDictContainsSubset
2019-01-28 14:14:23 +01:00
Matthias Urlichs
e056ccdf29
Testing: exception args
2019-01-28 14:14:23 +01:00
Matthias Urlichs
e334d8b073
Testing: file modes
2019-01-28 14:14:23 +01:00
Matthias Urlichs
f1673c148f
str vs utf
2019-01-28 14:14:23 +01:00
Matthias Urlichs
7fcc3551ca
We need text mode for JSON and YAML
2019-01-28 14:14:23 +01:00
Matthias Urlichs
f3fdac7e5a
Use raw strings for all regexps.
...
No exceptions please.
2019-01-28 14:14:23 +01:00
Matthias Urlichs
a1a15e40e0
Replace all bare "except:" handlers
...
These are never what we want, as they swallow KeyboardInterrupt.
TODO: many of these handlers really should be more specific and/or
log that they replaced an unparseable value with a default.
2019-01-28 07:50:55 +01:00
Matthias Urlichs
70a104e32a
shebang python2 => python
2019-01-28 07:50:54 +01:00
Matthias Urlichs
f9916783e9
whitespace
2019-01-28 07:34:19 +01:00
Matthias Urlichs
c05b6572c5
Fix coding= headers
2019-01-27 17:36:16 +01:00
Matthias Urlichs
958fc7600d
Merge commit 'e0543de8ef5c1f67d4064e84a5e7ecacbdf1029e' into py23
2019-01-27 17:15:52 +01:00
Matthias Urlichs
353309fc60
Merge commit 'd3334b29d9124b8a9e9c2dbfcdd6e125e471c412' into py23
2019-01-27 17:13:28 +01:00
Matthias Urlichs
f993f744ba
Merge commit 'c623e90ebc59b90b4f4cf582ab8185b2872acff4'; commit 'f416e96414f33fb31afdf4dfbf3c863e3db35543'; commit '9ecf39febe31a44e5f5db28249ebbf006ac1580c'; commit '582b03f21fe3d808bf4e11bbba90af54b6651b34'; commit 'f5c8b04958170f19f1806b1722bf5e857ded3dce'; commit '36818057a3b4769a77731f3be8bc661437db7132'; commit 'd987cb23c119132b287f70f1c979aac8c9fff7d2' into py23
2019-01-27 17:10:01 +01:00
MirceaDan
f243a52823
all files start now with same 2 lines
...
# coding=utf-8
from __future__ import absolute_import, division, print_function
2018-12-02 02:13:12 -08:00
MirceaDan
d3334b29d9
fix for tests and previous commit regarding estimations
...
tests needed updated None replaced with -1
2018-12-01 22:26:30 -08:00
MirceaDan
c623e90ebc
chnaged teh default from binary to text mode
...
seams like open was defaulting to text mode, since now is specified in clear i made sure it matches with teh previous default
2018-12-01 17:43:19 -08:00
MirceaDan
b6e49b59a7
unitest update to decode utf8
...
TypeError: write() argument 1 must be unicode, not str
2018-12-01 17:11:07 -08:00
MirceaDan
347f53baa4
file must be open in text mode
...
those files must be opened in text mode in python3
2018-12-01 16:36:11 -08:00
MirceaDan
9ecf39febe
we need a list not a map object
...
AssertionError: Second sequence is not a list: <map object at 0x7f7b0d3811d0>
2018-12-01 16:26:43 -08:00
MirceaDan
ff0b94c78d
py23 compat: list is needed not a view
...
in py3 keys() returns a view but in this cases we need a list
2018-12-01 15:42:01 -08:00
MirceaDan
a5cff5bc3d
this file must be opened in text mode
...
the version file must be read in text mode
2018-12-01 12:19:30 -08:00
MirceaDan
6b149e2fc9
fixed unitests for io.open change
...
the fixups needed change to use io.open in mock
some io.open needed to be read as text
2018-12-01 11:57:10 -08:00
MirceaDan
337e49208a
py23 compat: using io.open instead of open
...
for python3 and python2 to work teh same io.open must be used for file handling
2018-11-30 00:32:57 -08:00
Gina Häußge
b052925424
Merge remote-tracking branch 'origin/devel' into devel
...
# Conflicts:
# tests/filemanager/test_filemanager.py
2018-11-28 17:37:47 +01:00
Gina Häußge
88c93a7c11
Merge branch 'maintenance' into devel
...
# Conflicts:
# setup.py
2018-11-13 16:22:07 +01:00
tedder
98c84b6bb9
fix test, match dict
2018-11-08 01:34:45 +00:00
Gina Häußge
e522633c98
Merge branch 'maintenance' into devel
...
# Conflicts:
# AUTHORS.md
# src/octoprint/plugins/pluginmanager/__init__.py
# src/octoprint/plugins/softwareupdate/__init__.py
# src/octoprint/server/__init__.py
# src/octoprint/server/api/__init__.py
# src/octoprint/server/util/flask.py
# src/octoprint/server/util/sockjs.py
# src/octoprint/server/util/tornado.py
# src/octoprint/static/js/app/client/base.js
# src/octoprint/users.py
2018-11-06 11:57:57 +01:00
Gina Häußge
3ad4818488
Use read instead of write mode in _load_yaml
2018-10-30 16:56:14 +01:00
Gina Häußge
169275b052
Fix wrong position of parentheses, add unit tests
2018-10-19 16:39:18 +02:00
Gina Häußge
ac2354907a
Remove some trailing whitespace
2018-10-18 17:33:08 +02:00
Gina Häußge
7b5d2e3e0c
Allow whitespace after : in M114 responses
...
Closes #2839
2018-10-18 17:32:32 +02:00
Gina Häußge
5ff790048d
Fix unit tests
2018-09-26 15:52:10 +02:00
tedder
743ff35bcf
add some yaml wrappers for the test environment
2018-09-22 18:05:10 -07:00
tedder
df706f61db
import locally for py3 mock compatability
2018-09-22 17:21:33 -07:00
tedder
22fdc1d933
final open mock tactic: add a central global.
2018-09-22 16:58:24 -07:00
tedder
aa383e3ca1
fix all __builtin__.open patch/mock calls
2018-09-22 16:15:22 -07:00
tedder
bd35de80c3
fix test_file_helpers, couldn't figureout a non-conditional way to do this
2018-09-22 15:55:19 -07:00
tedder
c2f09b1715
fixes to test_comm_helpers
2018-09-22 13:14:27 -07:00
Gina Häußge
10f3f72b9c
Unit tests: Fix duplicated test method
...
Closes #2805
2018-09-21 14:35:20 +02:00
Gina Häußge
1ccc1fa47b
Merge pull request #2807 from tedder/201809_py3_devel_prep_b
...
201809 py3 devel prep batch b
2018-09-21 12:20:44 +02:00
tedder
2972d38cef
use a number instead of a string for safe_dump
2018-09-18 08:54:58 -07:00
Gina Häußge
2c50aa789a
Merge branch 'pr/2733' into devel
...
# Conflicts:
# src/octoprint/plugins/discovery/__init__.py
2018-09-18 17:30:30 +02:00
Gina Häußge
a920c4fe21
Merge pull request #2806 from tedder/201809_rewrite_test_get_recovery
...
rewrite test_get_recovery_data
2018-09-18 17:12:27 +02:00
Gina Häußge
52468e7e1c
Merge pull request #2802 from tedder/201809_temperature_regex_update
...
201809 temperature regex update
2018-09-18 17:10:37 +02:00
Gina Häußge
75c801d63f
Unit tests for is_lan_address
...
Also fixed a bug in subnet creation in the process.
2018-09-04 14:01:31 +02:00
tedder
7867052339
another 'set equality', this one to fix map/list mappings
2018-09-02 00:44:30 -07:00
tedder
8a0252ccfe
add patch workaround for py2/py3
2018-09-02 00:16:06 -07:00