twisted/mantissa

test errors, failure in suite of mantissa-0.8.0

Closed this issue · 4 comments

under python2.7

===============================================================================
[TODO]
Reason: 'currently gets too many results because we should be using paginate'
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_sharing.py", line 708, in test_limitEfficiency
    self.assertEquals(before, after)
  File "/usr/lib64/python2.7/site-packages/twisted/trial/_synctest.py", line 437, in assertEqual
    super(_Assertions, self).assertEqual(first, second, msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 513, in assertEqual
    assertion_func(first, second, msg=msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 506, in _baseAssertEqual
    raise self.failureException(msg)
twisted.trial.unittest.FailTest: 40 != 60

xmantissa.test.test_sharing.AccessibilityQuery.test_limitEfficiency
===============================================================================
[TODO]
Reason: 'is this a bug?  it seems like one to me'
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_tdb.py", line 216, in testTwoPageNextLastEquality
    assertSecondPage()
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_tdb.py", line 208, in <lambda>
    assertSecondPage = lambda: self.assertNumbersAre(tdm, range(100, 107))
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_tdb.py", line 75, in assertNumbersAre
    self.assertEquals(list(x.get('number') for x in tdm.currentPage()), seq)
  File "/usr/lib64/python2.7/site-packages/twisted/trial/_synctest.py", line 437, in assertEqual
    super(_Assertions, self).assertEqual(first, second, msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 513, in assertEqual
    assertion_func(first, second, msg=msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 742, in assertListEqual
    self.assertSequenceEqual(list1, list2, msg, seq_type=list)
  File "/usr/lib64/python2.7/unittest/case.py", line 724, in assertSequenceEqual
    self.fail(msg)
twisted.trial.unittest.FailTest: Lists differ: [7, 8, 9, 10, 11, 12, 13, 14, ... != [100, 101, 102, 103, 104, 105,...

First differing element 0:
7
100

First list contains 93 additional elements.
First extra element 7:
14

Diff is 742 characters long. Set self.maxDiff to None to see it.

xmantissa.test.test_tdb.ModelTest.testTwoPageNextLastEquality
===============================================================================
[FAIL]
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_stats.py", line 65, in test_deliverStatEvents
    ('quux', u'\N{SNOWMAN}'.encode('utf-8'))]))
  File "/usr/lib64/python2.7/site-packages/twisted/trial/_synctest.py", line 437, in assertEqual
    super(_Assertions, self).assertEqual(first, second, msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 513, in assertEqual
    assertion_func(first, second, msg=msg)
  File "/usr/lib64/python2.7/unittest/case.py", line 796, in assertSetEqual
    self.fail(self._formatMessage(msg, standardMsg))
twisted.trial.unittest.FailTest: Items in the first set but not the second:
('log_namespace', 'log_legacy')
('log_level', '<LogLevel=info>')
('log_time', '1437299850.22')
('log_system', '-')

xmantissa.test.test_stats.RemoteStatsCollectorTest.test_deliverStatEvents
===============================================================================
[ERROR]
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_howtolistings.py", line 184, in setUp
    import cal
exceptions.ImportError: No module named cal

xmantissa.test.test_howtolistings.InterstoreMessagingDocumentationTests.test_powerUp
===============================================================================
[ERROR]
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mantissa-0.8.0/work/Mantissa-0.8.0/xmantissa/test/test_howtolistings.py", line 88, in setUp
    import aboutpage
exceptions.ImportError: No module named aboutpage

xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_adminRedirect
xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_interface
xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_notOtherResources
xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_powerItUp
xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_produceAboutResource
xmantissa.test.test_howtolistings.SiteRootDocumentationTest.test_rendering
===============================================================================
[SUCCESS!?!]
Reason: 'Index scan to find appropriate storeID starting point once the value index has been used to seek to /near/ the correct starting place causes this to be O(N) on the number of rows with duplicate values.'

xmantissa.test.test_scrolltable.InequalityPerformanceTests.test_rowsAfterItemWithDuplicatesAtStart
xmantissa.test.test_scrolltable.InequalityPerformanceTests.test_rowsBeforeItemWithDuplicatesAtStart
-------------------------------------------------------------------------------
Ran 1105 tests in 240.999s

FAILED (skips=67, expectedFailures=2, failures=1, errors=7, unexpectedSuccesses=2, successes=1026)

What or where are these missing modules cal aboutpage and adminpage? ERROR; is listed only twice, so I am presuming that the absence of modules cal & aboutpage invoked 1 error re cal and 6 re aboutpage.

The logging failure is caused by the new Twisted logging system, and is fixed by #26; I was going to release a 0.8.1 including this and the StringEndpointPort fixes, but I forgot, so I'm doing that as I write this.

aboutpage.py and adminpage.py are in doc/listings/siteroot. I suspect the reason they are failing is that you are running the tests on an installed copy of Mantissa, but the doc/ dir is not installed by setup.py, so the tests fail. The tests should probably just be skipped if the listings can't be imported.

(The "TODO" tests are tests that fail, but are marked as expected to fail (they represent functionality that is not yet implemented), so you can ignore those. SUCCESS!?! is a test marked todo that succeeded anyway, hence "unexpected success").

right thanks. SO if PYTHONPATH has the doc/listings/siteroot added it should pick them up, except

$ ls
axiom LICENSE MANIFEST.in Mantissa.egg-info NAME.txt nevow NEWS.txt PKG-INFO README.txt setup.cfg setup.py xmantissa

No doc folder. I wonder if in the next release you could recursive-include the docs folder in MANIFEST.in.

$ ls /path/to//Mantissa-0.8.1/

yields

LICENSE MANIFEST.in Mantissa.egg-info NAME.txt NEWS.txt PKG-INFO README.txt axiom nevow setup.cfg setup.py xmantissa

still no doc folder.


Ran 1089 tests in 238.530s

FAILED (skips=66, expectedFailures=2, failures=11, errors=115, unexpectedSuccesses=2, successes=918)

Tried running manually form source and it just halted eith hanging or taking an inordinate period of time to timeout and move on in some tests.

see https://gist.github.com/idella/aaba3da4641a771a123f

It has less tests run and has a far higher fail rate. The deps appear the same. You might prefer to split it into a new bug.

I opened #29 to cover the issue of the tests failing because the docs aren't installed. I think some of the test failures in your paste are caused by #30 as well.