Merge pull request #18381 from ktoso/wip-reenable-tests-ktoso
=htp #18361 reenable pending tests ported from spray
This commit is contained in:
commit
dfed97818f
2 changed files with 31 additions and 19 deletions
|
|
@ -117,6 +117,13 @@ object Marshaller
|
|||
*/
|
||||
def opaque[A, B](marshal: A ⇒ B): Marshaller[A, B] =
|
||||
strict { value ⇒ Marshalling.Opaque(() ⇒ marshal(value)) }
|
||||
|
||||
/**
|
||||
* Helper for creating a [[Marshaller]] combined of the provided `marshal` function
|
||||
* and an implicit Marshaller which is able to produce the required final type.
|
||||
*/
|
||||
def combined[A, B, C](marshal: A ⇒ B)(implicit m2: Marshaller[B, C]): Marshaller[A, C] =
|
||||
Marshaller[A, C] { ec ⇒ a ⇒ m2.compose(marshal).apply(a)(ec) }
|
||||
}
|
||||
//#
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue