t('Brazil Phone number test'), 'description' => t('Tests various valid and invalid Brazil phone numbers for validity'), 'group' => t('Phone') ); } public function testPhoneBRValid() { $this->assertTrue(valid_phone_number('br', '(11) 1234-5678'), t('Test valid')); $this->assertTrue(valid_phone_number('br', '1234-5678 '), t('Test valid')); $this->assertTrue(valid_phone_number('br', '12345678'), t('Test valid')); } public function testPhoneBRInvalid() { $this->assertFalse(valid_phone_number('br', '(11)1234-5678'), t('Test invalid')); $this->assertFalse(valid_phone_number('br', '123-45678'), t('Test invalid')); $this->assertFalse(valid_phone_number('br', '(10) 1234.5678'), t('Test invalid')); } public function testPhoneBRFormatting() { //$this->assertEqual(format_phone_number('br', '+6421123456', null), '+64 21 123 456', t('Check international mobile format')); } }