Commit Graph

38 Commits

Author SHA1 Message Date
qubesuser
f2b8ad7d38 remove unused netid code
it's unused and has a netid property with name different than key
that would cause issues in the next commit
2017-11-11 02:37:37 +01:00
Marek Marczykowski-Górecki
e2eaa57f65
Merge branch 'tests-20171020'
* tests-20171020:
  tests: fix asyncio usage some more places
  tests: fix reporting in network tests
  tests: domain-shutdown event race condition
  tests: improve events tests
  tests: fix logic error in wait_for_window()
  tests: cleanup QubesDB connection on domain remove
2017-10-21 04:33:35 +02:00
Marek Marczykowski-Górecki
96f2e503db
tests: improve events tests
Check property-related events, including their arguments.
2017-10-21 04:06:15 +02:00
Marek Marczykowski-Górecki
038ca6d5d7
base: add method for getting default property value
Allow to get default value even it isn't set currently. This will allow
(G)UI to present better view, without duplicating logic for default
value.

Fixes QubesOS/qubes-issues#3197
2017-10-21 04:05:15 +02:00
Marek Marczykowski-Górecki
2164a8d7b8
Change license to LGPL v2.1+
See this thread for reasoning and acceptance from contributors:
https://groups.google.com/d/topic/qubes-devel/G7KzrfU0lWY/discussion
"Changing qubes-core-admin license to LGPL v2.1+"
2017-10-12 00:11:50 +02:00
Wojtek Porczyk
bd123a3812 tests: fix some memory leaks
This is work in progress. There are still more leaks.
2017-09-19 17:01:29 +02:00
Marek Marczykowski-Górecki
1af7034d57
tests: more tests fixes 2017-07-26 03:26:58 +02:00
Wojtek Porczyk
df03800278 Fix miscellaneous warnings
Among them:
- explicitly close files (possibly using with: syntax)
- use non-deprecated methods
2017-05-29 17:34:15 +02:00
Wojtek Porczyk
b256af3bfb qubes.tests asyncio
QubesOS/qubes-issues#2622
2017-05-29 17:34:15 +02:00
Wojtek Porczyk
be53db4db9 qubes/events: they accept only keyword arguments
Positional arguments are hereby deprecated, with immediate effect.

QubesOS/qubes-issues#2622
2017-02-21 14:46:42 +01:00
Wojtek Porczyk
d74567d65f qubes: port core to python3
fixes QubesOS/qubes-issues#2074
2017-01-20 16:42:51 +01:00
Bahtiar `kalkin-` Gadimov
71161bfb93
Add mock libvirt objects 2016-07-13 23:28:02 +02:00
Bahtiar `kalkin-` Gadimov
23e52775b6
qubes.tests.init make pylint happy ♥ 2016-07-13 23:08:58 +02:00
Bahtiar `kalkin-` Gadimov
774cbd499e
Add TestVM.is_halted() to fix failing tests 2016-07-13 21:57:12 +02:00
Wojtek Porczyk
6ade5736d7 pylint fixes 2016-06-10 21:27:29 +02:00
Wojtek Porczyk
3b08e85a2d qubes/tests/init: Fix VMCollection reference 2016-06-10 21:27:29 +02:00
Marek Marczykowski-Górecki
07b72ef3fd tests: fix after moving VMCollection to qubes.app 2016-06-02 12:37:30 +02:00
Wojtek Porczyk
786884ad7a qubes: fix netvm properties and tests
fixes QubesOS/qubes-issues#1816
2016-05-19 03:02:23 +02:00
Wojtek Porczyk
63c09a090c qubes: Combat import cycles
This commit eliminates import statements happening in the middle of the
file (between two classes definition). The cycles are still there. The
only magic module is qubes itself.
2016-05-05 14:33:09 +02:00
Wojtek Porczyk
06cc064c8c qubes/tests: split init to init1 and init2
This is to keep the correct order of the tests. The exact dependency
graph is somewhat complicated and contains several cycles.
2016-01-21 13:31:43 +01:00
Wojtek Porczyk
b4d51b016b core3: some properties can be set only once
Some properties should not be changed by user at will (like UUID). The
solution is to make them write-once, so they will be set when loading
from XML and frozen for the lifespan of the object holding the property.
When desperately needed, users may edit XML by hand.

fixes QubesOS/qubes-issues#1235
2015-10-05 12:46:14 +02:00
Wojtek Porczyk
6241859dc8 qubes: Fix PropertyHolder.property_get_default
And test cases, some of them stubs.
2015-09-28 18:20:28 +02:00
Wojtek Porczyk
d5f2e6ab74 qubes: rework qubes.xml handling
Now it more closely aligns with old core2 semantics. New semantics will
have to wait for qubesd.
2015-06-29 17:39:28 +02:00
Wojtek Porczyk
5d9b92a039 qubes: pylint fixes (minor programming errors) 2015-06-29 17:39:28 +02:00
Wojtek Porczyk
adb144acfe qubes: pylint fixes (small mistakes and wrong names) 2015-06-29 17:39:27 +02:00
Wojtek Porczyk
bf29d5e5b5 qubes: pylint fixes (disable unfounded messages) 2015-06-29 17:39:27 +02:00
Wojtek Porczyk
ac1739df6b qubes: pylint fixes (fix imports) 2015-06-29 17:39:27 +02:00
Wojtek Porczyk
ee06e7d7a2 qubes: documentation and licence fixes 2015-06-29 17:39:27 +02:00
Wojtek Porczyk
cdc3df66c8 qubes: pylint fixes (mostly whitespace) 2015-06-29 17:39:27 +02:00
Wojtek Porczyk
8e16dd2b28 qubes/storage: fix storage instantiation 2015-06-29 17:39:26 +02:00
Wojtek Porczyk
a13a41fbaf qubes/tests: fix testrunner dependency on being run in specific directory 2015-06-29 17:39:26 +02:00
Wojtek Porczyk
eda2f7cf73 qubes/tests: mark one test as expected failure
This is temporary, to be fixed in the future.
2015-06-29 17:39:26 +02:00
Wojtek Porczyk
af154b53fe qubes: change names of XML generating methods
Methods returning lxml.etree.Elements are called xml_ or lvxml_, meant for
qubes.xml or libvirt respectively.

Acknowledgement:
This commit is a result of core3 review by Marek.
2015-06-29 17:39:26 +02:00
Wojciech Zygmunt Porczyk
42d8e67556 doc: Add autogenerated qubes.xml documentation 2015-06-29 17:39:25 +02:00
Wojtek Porczyk
6ec86ec9f7 qubes: property may be unset by assinging DEFAULT
Introducing qubes.property.DEFAULT special value, which may be assigned to any
property. Result is the same as del'ing a property.
2015-06-29 17:39:25 +02:00
Wojtek Porczyk
713ced8cd2 qubes/tests: add event asserts for qubes module 2015-06-29 17:39:25 +02:00
Wojtek Porczyk
74c3126b80 qubes/tests: add some tests for qubes.property 2015-06-29 17:39:25 +02:00
Wojtek Porczyk
a82bf7cc54 qubes/tests: Move unit tests inside qubes/, add runner 2015-06-29 17:39:24 +02:00