Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix all composer related tests (plus a bonus feature) #1044

Closed
wants to merge 12 commits into from

Conversation

nyalldawson
Copy link
Collaborator

The composer test suit is in bad shape at the moment. This pull request fixes all composer related tests which are currently failing. First it reworks qgscompositionchecker to derive from renderchecker (#9117), so that anomaly images can be set for composer tests (the old method of allowing a set number of differing pixels was too inflexible and allowed tests to pass when they shouldn't be, eg the composermap zebra style test). Then I've reworked all the compositionchecker related tests so that they all pass, in some cases adding anomaly images or fixing the underlying bugs.

It also adds a new feature required to fix the failing zebra style test (#8767), which is the ability to set the pen and colours used in zebra style maps.

The composer html tests had to be fixed by forcing the test html file to use a set pixel based font size and the expected images regenerated. This may mean they will currently fail on non-linux platforms, but fixing this will be a simple matter of adding anomaly images for these platforms.

@nyalldawson
Copy link
Collaborator Author

I should mention that I'd love a speedy review on this one -- the current state of the test suite is really hampering my development work! :)

@nyalldawson
Copy link
Collaborator Author

Manually applied

@timlinux
Copy link
Member

Thanks @nyalldawson

Jenkins still seems to not be building automatically properly - I am looking in to why. FYI I started it manually again and get this list of failing tests:

79% tests passed, 17 tests failed out of 80

Total Test time (real) = 320.76 sec

The following tests FAILED:
      9 - qgis_rasterlayertest (Failed)
     14 - qgis_rendererstest (Failed)
     15 - qgis_maprenderertest (Failed)
     25 - qgis_composermaptest (Failed)
     28 - qgis_atlascompositiontest (Failed)
     30 - qgis_stylev2test (Failed)
     31 - qgis_composerhtmltest (Failed)
     33 - qgis_composerscalebartest (Failed)
     34 - qgis_ogcutilstest (Failed)
     35 - qgis_vectorlayercachetest (Failed)
     46 - qgis_wcsprovidertest (Failed)
     53 - PyQgsRasterLayer (Failed)
     63 - PyQgsComposerHtml (Failed)
     66 - PyQgsComposerMap (Failed)
     69 - PyQgsSymbolLayerV2 (Failed)
     71 - PyQgsAtlasComposition (Failed)
     75 - PyQgsPalLabelingCanvas (Failed)
Performing coverage

I will check and add anomaly files where I can.

Note the build was against 21d3fe1

@timlinux
Copy link
Member

Great enhancements on the zebra border thanks! By the way the zebra border seems to not update cleanly when you change its properties - I often need to force the page to reset to see my settings on screen. Also resizing often leaves behind a ghost of the old frame e.g.:

composer 2_063

@nyalldawson
Copy link
Collaborator Author

@timlinux That's a known issue - it's somewhat related to http://hub.qgis.org/issues/8993 . Basically the map frame and annotations are being drawn outside of the item bounds, which causes artefacts like this. It's on my to-repair list.
And thanks in advance for adding anomaly images... I didn't realise how many would be required to get the tests to pass cleanly on all platforms!

@nyalldawson nyalldawson deleted the fix_tests branch December 30, 2013 09:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants