'Test the find action data regex.'

def testFindAction3(self):

    pathspec = rdf_paths.PathSpec(path='/mock2/', pathtype=rdf_paths.PathSpec.PathType.OS)
    request = rdf_client.FindSpec(pathspec=pathspec, data_regex='Secret', cross_devs=True)
    request.iterator.number = 200
    result = self.RunAction(searching.Find, request)
    all_files = [x.hit for x in result if isinstance(x, rdf_client.FindSpec)]
    self.assertEqual(len(all_files), 2)
    self.assertEqual(all_files[0].pathspec.Basename(), 'file1.txt')
    self.assertEqual(all_files[1].pathspec.Basename(), 'long_file.text')
