@@ -836,6 +836,21 @@ public function test_it_tokenizes_enum_column()
836836 $ this ->assertEquals ('$table->enum( \'status_flag \', [ \'1 \', \'2 \', \'3 \', \'4 \']) ' , $ columnDefinition ->render ());
837837 }
838838
839+ public function test_it_tokenizes_enum_column_with_upper_case_values ()
840+ {
841+ $ columnTokenizer = ColumnTokenizer::parse ('`film_rating` enum( \'G \', \'PG \', \'PG-13 \', \'R \', \'NC-17 \') ' );
842+ $ columnDefinition = $ columnTokenizer ->definition ();
843+
844+ $ this ->assertEquals ('film_rating ' , $ columnDefinition ->getColumnName ());
845+ $ this ->assertEquals ('enum ' , $ columnTokenizer ->getColumnDataType ());
846+ $ this ->assertEquals ('enum ' , $ columnDefinition ->getMethodName ());
847+ $ this ->assertCount (5 , $ columnDefinition ->getMethodParameters ()[0 ]);
848+ $ this ->assertEqualsCanonicalizing (['G ' , 'PG ' , 'PG-13 ' , 'R ' , 'NC-17 ' ], $ columnDefinition ->getMethodParameters ()[0 ]);
849+ $ this ->assertNull ($ columnDefinition ->isNullable ());
850+ $ this ->assertNull ($ columnDefinition ->getCollation ());
851+ $ this ->assertEquals ('$table->enum( \'film_rating \', [ \'G \', \'PG \', \'PG-13 \', \'R \', \'NC-17 \']) ' , $ columnDefinition ->render ());
852+ }
853+
839854 public function test_it_tokenizes_not_null_enum_column ()
840855 {
841856 $ columnTokenizer = ColumnTokenizer::parse ('`status_flag` enum( \'1 \', \'2 \', \'3 \', \'4 \') NOT NULL ' );
0 commit comments