Example #1
0
 /**
  * test charset getter
  */
 public function testCharset()
 {
     // test some returns
     $this->assertEquals(CCStr::charset('password'), CCStr::SECURE);
     $this->assertEquals(CCStr::charset('secure'), CCStr::SECURE);
     $this->assertEquals(CCStr::charset('pass'), CCStr::SECURE);
     $this->assertEquals(CCStr::charset('hex'), CCStr::HEX);
     $this->assertEquals(CCStr::charset('bin'), CCStr::BIN);
     $this->assertEquals(CCStr::charset('pass'), CCStr::SECURE);
     $this->assertEquals(CCStr::charset('alpha_low'), CCStr::ALPHA_LOW);
     $this->assertEquals(CCStr::charset('lowercase'), CCStr::ALPHA_LOW);
     // custom
     $this->assertEquals(CCStr::charset('customchaset'), 'customchaset');
 }