19 declare(strict_types=1);
29 require_once(
'./vendor/composer/vendor/autoload.php');
35 $value =
new Alphanumeric(
'hello');
37 $this->assertSame(
'hello', $value->asString());
42 $value =
new Alphanumeric(6);
44 $this->assertSame(
'6', $value->asString());
49 $value =
new Alphanumeric(6);
51 $this->assertSame(6, $value->getValue());
56 $value =
new Alphanumeric(6.0);
58 $this->assertSame(
'6', $value->asString());
63 $value =
new Alphanumeric(6.0);
65 $this->assertSame(6.0, $value->getValue());
70 $this->expectNotToPerformAssertions();
73 $value =
new Alphanumeric(
'hello world');
testIntegerIsAlphanumericValueAndCanBeConvertedToString()
testFloatIsAlphanumericValue()
testSimpleStringIsCorrectAlphanumericValueAndCanBeConvertedToString()
testIntegerIsAlphanumericValue()
testFloatIsAlphanumericValueAndCanBeConvertedToString()
testTextIsNotAlphanumericAndWillThrowException()