Skip to content

Allow user to override content type #24

@mefellows

Description

@mefellows

I'm writing a test for a Twirp client using this package, and have noticed it doesn't add the ;message=WhateverIAmSending parameter on the content type.

This results in the following failure:

  Mock server failed with the following mismatches:

	0) The following request was incorrect:

            	POST /twirp/twirp.example.haberdasher.Haberdasher/FindHat

			 1.0 Expected body with content type application/protobuf;message=FindHatRPC but was application/protobuf

In this case, the client is not configurable to override this, and it's not clear (at least to me) if this is the standard Twirp behaviour (perhaps it's a gRPC specific thing?), and so it seems it's not safe to assume this content-type.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions