HM\BackUpWordPress\Site_Size_Tests::test_file_size_not_excluded_directly PHP Method

test_file_size_not_excluded_directly() public method

Main test: Site_Size->filesize( $file ) Expected: file size should be what it is.
    public function test_file_size_not_excluded_directly()
    {
        $file_path = $this->test_data . '/test-data.txt';
        $file = new \SplFileInfo($file_path);
        // Check the file is created and its size is NOT 0.
        $this->assertContains($this->root->getPath(), $file->getPath());
        $this->assertNotSame($file->getSize(), 0);
        // Check file size via BWP function. It should NOT be 0, should be the same size as via getSize().
        $site_size = new Site_Size('file');
        $this->assertNotSame($site_size->filesize($file), 0);
        $this->assertSame($site_size->filesize($file), $file->getSize());
    }