def METHOD_NAME(self, text, languages, error_code=None):
    expected_params = {'Text': text}
    response = {'Languages': languages}
    self._stub_bifurcator(
        'detect_dominant_language', expected_params, response,
        error_code=error_code)