File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -793,22 +793,23 @@ public function testUploadingAnEmptyFile(): void
793
793
794
794
$ expected = [
795
795
'length ' => 0 ,
796
- 'md5 ' => 'd41d8cd98f00b204e9800998ecf8427e ' ,
797
796
];
798
797
799
798
$ this ->assertSameDocument ($ expected , $ fileDocument );
799
+ $ this ->assertArrayNotHasKey ('md5 ' , $ fileDocument );
800
800
}
801
801
802
- public function testDisableMD5 (): void
802
+ public function testEnableMD5 (): void
803
803
{
804
- $ options = ['disableMD5 ' => true ];
804
+ $ options = ['disableMD5 ' => false ];
805
805
$ id = $ this ->bucket ->uploadFromStream ('filename ' , $ this ->createStream ('data ' ), $ options );
806
806
807
807
$ fileDocument = $ this ->filesCollection ->findOne (
808
808
['_id ' => $ id ],
809
809
);
810
810
811
- $ this ->assertArrayNotHasKey ('md5 ' , $ fileDocument );
811
+ $ this ->assertArrayHasKey ('md5 ' , $ fileDocument );
812
+ $ this ->assertSame ('8d777f385d3dfec8815d20f7496026dc ' , $ fileDocument ['md5 ' ]);
812
813
}
813
814
814
815
public function testDisableMD5OptionInConstructor (): void
You can’t perform that action at this time.
0 commit comments