File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -124,6 +124,19 @@ public function testKeys()
124
124
$ this ->assertEquals (array ('notice ' ), $ this ->bag ->keys ());
125
125
}
126
126
127
+ public function testSetAll ()
128
+ {
129
+ $ this ->bag ->add ('one_flash ' , 'Foo ' );
130
+ $ this ->bag ->add ('another_flash ' , 'Bar ' );
131
+ $ this ->assertTrue ($ this ->bag ->has ('one_flash ' ));
132
+ $ this ->assertTrue ($ this ->bag ->has ('another_flash ' ));
133
+ $ this ->bag ->setAll (array ('unique_flash ' => 'FooBar ' ));
134
+ $ this ->assertFalse ($ this ->bag ->has ('one_flash ' ));
135
+ $ this ->assertFalse ($ this ->bag ->has ('another_flash ' ));
136
+ $ this ->assertSame (array ('unique_flash ' => 'FooBar ' ), $ this ->bag ->all ());
137
+ $ this ->assertSame (array (), $ this ->bag ->all ());
138
+ }
139
+
127
140
public function testPeekAll ()
128
141
{
129
142
$ this ->bag ->set ('notice ' , 'Foo ' );
You can’t perform that action at this time.
0 commit comments