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

tidy string/primitive coercion #1037

Merged
merged 3 commits into from Feb 11, 2019
Merged

Conversation

ahgittin
Copy link
Contributor

@ahgittin ahgittin commented Feb 8, 2019

changes to use a Maybe allow for additional rules to do more coercion

changes to use a Maybe allow for additional rules to do more coercion
@aledsage
Copy link
Contributor

@ahgittin test failure looks related to changes (TypeCoercionsTest.testCoercePrimitiveFailures):

java.lang.AssertionError: Error from type coercion of maybe to boolean failed with wrong exception; expected match of Predicates.and(containsLiteral("String"),containsLiteral("boolean"),containsLiteral("maybe")) but got: org.apache.brooklyn.util.javalang.coerce.ClassCoercionException: Cannot coerce type String to java.lang.Boolean (maybe): adapting failed
	at org.apache.brooklyn.util.javalang.coerce.TypeCoercionsTest.assertCoercionFailsWithErrorMatching(TypeCoercionsTest.java:154)
	at org.apache.brooklyn.util.javalang.coerce.TypeCoercionsTest.testCoercePrimitiveFailures(TypeCoercionsTest.java:140)

@aledsage
Copy link
Contributor

Other than failing unit test, LGTM. Happy for this to be merged once that is fixed @ahgittin

@ahgittin
Copy link
Contributor Author

server-side testing looks broken or slow -- tests pass locally now. merging.

@asfgit asfgit merged commit 360c4eb into apache:master Feb 11, 2019
asfgit pushed a commit that referenced this pull request Feb 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants