Comments (11)
Thanks a lot, @akx!
from wagtail-svgmap.
Would be great! PR much appreciated. =)
from wagtail-svgmap.
Any idea how I've broken these unit tests?
https://travis-ci.org/City-of-Helsinki/wagtail-svgmap/jobs/338979401
Probably something silly I've done, but might be something more easily fixed by someone that knows the codebase ?
from wagtail-svgmap.
Since dependencies haven't been locked (which is a good idea for a library like this), it's just "test rot" as dependencies have changed between the last successful test and this.
Among others (which I elided here for brevity), these have updated:
Django 1.10.2 -> 1.11.10
django-modelcluster 2.0 -> 3.1
django-taggit 0.18.3 -> 0.22.2
django-treebeard 4.0.1 -> 4.2.0
djangorestframework 3.4.7 -> 3.6.4
Pillow 3.4.1 -> 5.0.0
wagtail 1.6.3 -> 1.13.1
Willow-0.3.1 -> Willow 1.0
The test_page_creation
test with this
> assert example_map_option.get('selected')
E assert ''
E + where '' = <bound method Tag.get of <option selected="" value="1">Example Map ZsbCrN2Ir3Sm</option>>('selected')
E + where <bound method Tag.get of <option selected="" value="1">Example Map ZsbCrN2Ir3Sm</option>> = <option selected="" value="1">Example Map ZsbCrN2Ir3Sm</option>.get
failure could be that Wagtail or Django has changed the way selected
gets serialized in the admin. The simple fix is likely to just change assert example_map_option.get('selected')
to assert example_map_option.get('selected') is not None
.
The second failure has to do with what the view's context contains. It's obviously used to contain form
at some point, but it might be something else like delete_form
with the new package versions.
from wagtail-svgmap.
@stuaxo I fixed those issues in #15, so if you rebase #14 on top of master, you should be able to continue.
Also, I added Wagtail version variations to .travis.yml, which you should be able to use to also test against Wagtail 2.0 (beta?).
from wagtail-svgmap.
Cheers, will do.
The wagtail version is the newest 2.x on pypi, currently wagtail==2.0b1
Since they recommend projects to be on 2, I'd expect a non beta release relatively soon.
from wagtail-svgmap.
Oops, merged, not rebased, seemed to get away with it as tests pass now :)
The only complication is sorting travis - since wagtail doesn't support python 2.7.
from wagtail-svgmap.
Set up a build matrix exclude clause. For instance if the WAGTAIL
envvar is wagtail==2.0b1
, add that to the env
list and then an exclude stanza like this:
matrix:
exclude:
- python: 2.7
env: WAGTAIL=WAGTAIL==2.0b1
from wagtail-svgmap.
(excuse the scrappy commit history, squash these if they get merged :)
I managed to really confuse myself about build matrices - it still seems to try and build with python 2.7 on my current .travis -
https://github.com/stuaxo/wagtail-svgmap/blob/821416843fba340afd3c87365fa09d22c9e0ce87/.travis.yml
from wagtail-svgmap.
OK, commits all squashed and got everything working in the wsm_test dir.
Didn't manage to work out the excludes thing, but I'll leave that for now.
In wsm_test:
Possible breaking change is I removed the session auth middleware - it doesn't exist in 2.0 and is implicit in 1.10.
Newer wagtail needs on_delete on Foreign keys, so I set this to SET_NULL
from wagtail-svgmap.
Closed as PR was merged.
from wagtail-svgmap.
Related Issues (10)
- Use FileFields for SVG instead of Wagtaildocs
- Add wagtailmodeladmin-based admin for imagemaps
- Regions are not updated when new SVG file is uploaded HOT 2
- SVG images on non-Edge IE are 150px in height HOT 4
- ImageMapBlock.map reset to None when editing an existing page HOT 2
- Updating an SVG file in an ImageMap results in an assertion failure HOT 1
- How to render the image map ? HOT 1
- How to remove css_class from the field
- Compatibility with Wagtail 4, Django 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wagtail-svgmap.