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

register model extractors for custom types #286

Merged
merged 3 commits into from Jul 22, 2016

Conversation

Projects
None yet
3 participants
@ancho
Member

ancho commented Jun 11, 2016

This is an attempt to fix #283
It register model extractors for custom types during DelegatingTemplateEngine construction.
I couldn't resist to move a few things around and refactor a bit here and there.

The renderCustomTypePaper Test in GroovyMarkupTemplateEngineRenderingTest could be moved to the AbstractTemplateEngineRenderingTest to test the behaviour of all template engines.

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Jun 11, 2016

Coverage Status

Coverage increased (+0.8%) to 65.679% when pulling 4743581 on ancho:feature/fix-custom-types into a71fea0 on jbake-org:master.

coveralls commented Jun 11, 2016

Coverage Status

Coverage increased (+0.8%) to 65.679% when pulling 4743581 on ancho:feature/fix-custom-types into a71fea0 on jbake-org:master.

@jonbullock

This comment has been minimized.

Show comment
Hide comment
@jonbullock

jonbullock Jul 13, 2016

Member

I noticed this adds published_<type>s to the data model as well, I'll have to remember to update the docs to include details about this as well.

Member

jonbullock commented Jul 13, 2016

I noticed this adds published_<type>s to the data model as well, I'll have to remember to update the docs to include details about this as well.

@jonbullock jonbullock added the bug label Jul 13, 2016

@jonbullock jonbullock added this to the v2.5.0 milestone Jul 13, 2016

@jonbullock jonbullock self-assigned this Jul 13, 2016

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Jul 14, 2016

Coverage Status

Coverage increased (+1.6%) to 69.143% when pulling ff6f12e on ancho:feature/fix-custom-types into 2f6bd13 on jbake-org:master.

coveralls commented Jul 14, 2016

Coverage Status

Coverage increased (+1.6%) to 69.143% when pulling ff6f12e on ancho:feature/fix-custom-types into 2f6bd13 on jbake-org:master.

@ancho

This comment has been minimized.

Show comment
Hide comment
@ancho

ancho Jul 14, 2016

Member

I rebased my branch to the latest master to make the merge easier.

Member

ancho commented Jul 14, 2016

I rebased my branch to the latest master to make the merge easier.

@jonbullock

This comment has been minimized.

Show comment
Hide comment
@jonbullock

jonbullock Jul 18, 2016

Member

Thanks @ancho - much appreciated.

Could I ask one more thing of you... that you keep the tests to JUnit for now? I'm not against switching over to Spock, but I'd prefer not to have some tests in one testing framework and the rest in another.

If Spock is the better choice then lets create a separate issue for the conversion of the whole test suite over to Spock.

Member

jonbullock commented Jul 18, 2016

Thanks @ancho - much appreciated.

Could I ask one more thing of you... that you keep the tests to JUnit for now? I'm not against switching over to Spock, but I'd prefer not to have some tests in one testing framework and the rest in another.

If Spock is the better choice then lets create a separate issue for the conversion of the whole test suite over to Spock.

@ancho

This comment has been minimized.

Show comment
Hide comment
@ancho

ancho Jul 18, 2016

Member

No problem @jonbullock

Spock is such a clean, nice and concise testing framework, I don't even think about whether to use it or not, I just do if I can.
It enables you to write really readable and understandable tests. The build-in mocking and stubbing support is really fun to use and the data centric test support is a dream.

I can backport it to junit and use mockito. Shouldn't be that hard. And maybe it is a good demonstration to see the two different approaches.

Member

ancho commented Jul 18, 2016

No problem @jonbullock

Spock is such a clean, nice and concise testing framework, I don't even think about whether to use it or not, I just do if I can.
It enables you to write really readable and understandable tests. The build-in mocking and stubbing support is really fun to use and the data centric test support is a dream.

I can backport it to junit and use mockito. Shouldn't be that hard. And maybe it is a good demonstration to see the two different approaches.

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Jul 18, 2016

Coverage Status

Coverage increased (+1.8%) to 69.333% when pulling 5a1e4c7 on ancho:feature/fix-custom-types into 2f6bd13 on jbake-org:master.

coveralls commented Jul 18, 2016

Coverage Status

Coverage increased (+1.8%) to 69.333% when pulling 5a1e4c7 on ancho:feature/fix-custom-types into 2f6bd13 on jbake-org:master.

@jonbullock

This comment has been minimized.

Show comment
Hide comment
@jonbullock

jonbullock Jul 22, 2016

Member

Amazing work thanks @ancho

Member

jonbullock commented Jul 22, 2016

Amazing work thanks @ancho

@jonbullock jonbullock merged commit d94e816 into jbake-org:master Jul 22, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@ancho ancho deleted the ancho:feature/fix-custom-types branch Oct 15, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment