public function testKeyboardButtonParameterSetting()
 {
     $button = new KeyboardButton('message');
     self::assertEmpty($button->getRequestContact());
     self::assertEmpty($button->getRequestLocation());
     $button->setRequestContact(true);
     self::assertTrue($button->getRequestContact());
     self::assertEmpty($button->getRequestLocation());
     $button->setRequestLocation(true);
     self::assertEmpty($button->getRequestContact());
     self::assertTrue($button->getRequestLocation());
 }
 /**
  * {@inheritdoc}
  */
 public function __call($method, $args)
 {
     // Only 1 of these can be set, so clear the others when setting a new one.
     if (in_array($method, ['setUrl', 'setCallbackData', 'setSwitchInlineQuery'], true)) {
         unset($this->url, $this->callback_data, $this->switch_inline_query);
     }
     return parent::__call($method, $args);
 }