def test_build_with_platform(self):
    self.mock_client.api_version = '1.35'
    self.mock_client.build.return_value = [b'{"stream": "Successfully built 12345"}']
    service = Service('foo', client=self.mock_client, build={'context': '.'}, platform='linux')
    service.build()
    assert (self.mock_client.build.call_count == 1)
    call_args = self.mock_client.build.call_args
    assert (call_args[1]['platform'] == 'linux')
def test_build_with_platform(self):
    self.mock_client.api_version = '1.35'
    self.mock_client.build.return_value = [b'{"stream": "Successfully built 12345"}']
    service = Service('foo', client=self.mock_client, build={'context': '.'}, platform='linux')
    service.build()
    assert (self.mock_client.build.call_count == 1)
    call_args = self.mock_client.build.call_args
    assert (call_args[1]['platform'] == 'linux')