There are a bunch of test failures, can you take a look at those?
[FAIL]
Traceback (most recent call last):
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/mocker.py", line 146, in test_method_wrapper
result = test_method()
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/lib/tests/test_sysstats.py", line 42, in test_get_memory_info
self.assertEqual(memstats.free_memory, 503)
File "/usr/lib/python2.7/dist-packages/twisted/trial/unittest.py", line 271, in assertEqual
% (msg, pformat(first), pformat(second)))
twisted.trial.unittest.FailTest: not equal:
a = 852
b = 503
landscape.lib.tests.test_sysstats.MemoryStatsTest.test_get_memory_info
===============================================================================
[FAIL]
Traceback (most recent call last):
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/mocker.py", line 146, in test_method_wrapper
result = test_method()
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/monitor/tests/test_memoryinfo.py", line 154, in test_exchange_messages
(step_size * 2, 503, 1567)]}])
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/helpers.py", line 82, in assertMessages
self.assertMessage(obtained_message, expected_message)
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/helpers.py", line 76, in assertMessage
pprint.pformat(obtained)))
twisted.trial.unittest.FailTest: Messages don't match.
Expected:
{'memory-info': [(300, 503, 1567), (600, 503, 1567)], 'type': 'memory-info'}
Obtained:
{'memory-info': [(300, 852, 1567), (600, 852, 1567)], 'type': 'memory-info'}
landscape.monitor.tests.test_memoryinfo.MemoryInfoTest.test_exchange_messages
===============================================================================
[FAIL]
Traceback (most recent call last):
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/mocker.py", line 146, in test_method_wrapper
result = test_method()
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/monitor/tests/test_memoryinfo.py", line 78, in test_read_sample_data
self.assertEqual(message["memory-info"][0], (step_size, 503, 1567))
File "/usr/lib/python2.7/dist-packages/twisted/trial/unittest.py", line 271, in assertEqual
% (msg, pformat(first), pformat(second)))
twisted.trial.unittest.FailTest: not equal:
a = (300, 852, 1567)
b = (300, 503, 1567)
landscape.monitor.tests.test_memoryinfo.MemoryInfoTest.test_read_sample_data
===============================================================================
[FAIL]
Traceback (most recent call last):
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/tests/mocker.py", line 146, in test_method_wrapper
result = test_method()
File "/home/andreas/canonical/source/landscape-client/psusi/correct-free-mem/landscape/sysinfo/tests/test_memory.py", line 53, in test_run_adds_header
("Swap usage", "39%")])
File "/usr/lib/python2.7/dist-packages/twisted/trial/unittest.py", line 271, in assertEqual
% (msg, pformat(first), pformat(second)))
twisted.trial.unittest.FailTest: not equal:
a = [('Memory usage', '27%'), ('Swap usage', '39%')]
b = [('Memory usage', '34%'), ('Swap usage', '39%')]
landscape.sysinfo.tests.test_memory.MemoryTest.test_run_adds_header
-------------------------------------------------------------------------------
Ran 2168 tests in 176.331s
FAILED (skips=7, failures=4, successes=2157)
You can run the test suite with "trial landscape" inside the root of the ckeckout directory. You may need to install some extra packages.
Here is a list taken from one of our setup scripts. It may install more than you need, but it's a place to start if you get test errors due to missing packages:
function install_common_dev_tools {
apt_get install --no-install-recommends \ build-essential \
gcc \
python-dev \
bzr \
bzrtools \ exuberant-ctags \
pyflakes \
debhelper \
fakeroot \
devscripts \
dput \
xvfb
}
function install_client_deps {
# Notes:
# - libgudev-1.0-dev supposed to take care of gir1.*-gudev* deps.
# - hal/smart needed for client tests, even though they are optional
# on modern ubuntu releases
apt_get install --no-install-recommends \
acct \
python-dbus \
python-gdbm \ python-gobject \ python-twisted-core \ python-twisted-names \
python-lxml \
python-apt \ python-openssl \ libgudev-1.0-dev \
lsb-release \ perl-modules \ python-pycurl \
hal \ python-smartpm \ python-distutils-extra \
$GIR \
There are a bunch of test failures, can you take a look at those?
[FAIL] andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/mocker. py", line 146, in test_method_wrapper andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ lib/tests/ test_sysstats. py", line 42, in test_get_ memory_ info assertEqual( memstats. free_memory, 503) python2. 7/dist- packages/ twisted/ trial/unittest. py", line 271, in assertEqual trial.unittest. FailTest: not equal:
Traceback (most recent call last):
File "/home/
result = test_method()
File "/home/
self.
File "/usr/lib/
% (msg, pformat(first), pformat(second)))
twisted.
a = 852
b = 503
landscape. lib.tests. test_sysstats. MemoryStatsTest .test_get_ memory_ info ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= == andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/mocker. py", line 146, in test_method_wrapper andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ monitor/ tests/test_ memoryinfo. py", line 154, in test_exchange_ messages andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/helpers. py", line 82, in assertMessages assertMessage( obtained_ message, expected_message) andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/helpers. py", line 76, in assertMessage pformat( obtained) )) trial.unittest. FailTest: Messages don't match.
=======
[FAIL]
Traceback (most recent call last):
File "/home/
result = test_method()
File "/home/
(step_size * 2, 503, 1567)]}])
File "/home/
self.
File "/home/
pprint.
twisted.
Expected:
{'memory-info': [(300, 503, 1567), (600, 503, 1567)], 'type': 'memory-info'}
Obtained:
{'memory-info': [(300, 852, 1567), (600, 852, 1567)], 'type': 'memory-info'}
landscape. monitor. tests.test_ memoryinfo. MemoryInfoTest. test_exchange_ messages ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= == andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/mocker. py", line 146, in test_method_wrapper andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ monitor/ tests/test_ memoryinfo. py", line 78, in test_read_ sample_ data assertEqual( message[ "memory- info"][ 0], (step_size, 503, 1567)) python2. 7/dist- packages/ twisted/ trial/unittest. py", line 271, in assertEqual trial.unittest. FailTest: not equal:
=======
[FAIL]
Traceback (most recent call last):
File "/home/
result = test_method()
File "/home/
self.
File "/usr/lib/
% (msg, pformat(first), pformat(second)))
twisted.
a = (300, 852, 1567)
b = (300, 503, 1567)
landscape. monitor. tests.test_ memoryinfo. MemoryInfoTest. test_read_ sample_ data ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= == andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ tests/mocker. py", line 146, in test_method_wrapper andreas/ canonical/ source/ landscape- client/ psusi/correct- free-mem/ landscape/ sysinfo/ tests/test_ memory. py", line 53, in test_run_ adds_header python2. 7/dist- packages/ twisted/ trial/unittest. py", line 271, in assertEqual trial.unittest. FailTest: not equal:
=======
[FAIL]
Traceback (most recent call last):
File "/home/
result = test_method()
File "/home/
("Swap usage", "39%")])
File "/usr/lib/
% (msg, pformat(first), pformat(second)))
twisted.
a = [('Memory usage', '27%'), ('Swap usage', '39%')]
b = [('Memory usage', '34%'), ('Swap usage', '39%')]
landscape. sysinfo. tests.test_ memory. MemoryTest. test_run_ adds_header ------- ------- ------- ------- ------- ------- ------- ------- ------- ------- --
-------
Ran 2168 tests in 176.331s
FAILED (skips=7, failures=4, successes=2157)
You can run the test suite with "trial landscape" inside the root of the ckeckout directory. You may need to install some extra packages. common_ dev_tools { recommends \
build- essential \
exuberant- ctags \
Here is a list taken from one of our setup scripts. It may install more than you need, but it's a place to start if you get test errors due to missing packages:
function install_
apt_get install --no-install-
gcc \
python-dev \
bzr \
bzrtools \
pyflakes \
debhelper \
fakeroot \
devscripts \
dput \
xvfb
}
function install_client_deps { recommends \
python- gobject \
python- twisted- core \
python- twisted- names \
python- openssl \
libgudev- 1.0-dev \
perl-modules \
python- pycurl \
python- smartpm \
python- distutils- extra \
# Notes:
# - libgudev-1.0-dev supposed to take care of gir1.*-gudev* deps.
# - hal/smart needed for client tests, even though they are optional
# on modern ubuntu releases
apt_get install --no-install-
acct \
python-dbus \
python-gdbm \
python-lxml \
python-apt \
lsb-release \
hal \
$GIR \
GIR is "gir1.2-gtk-3.0 gir1.2-notify-0.7"