def METHOD_NAME(self):
    """Test that we can create a fileset aggregation from a folder that contains one file and delete the
    aggregation through the api"""
    self.create_composite_resource()
    new_folder = 'fileset_folder'
    ResourceFile.create_folder(self.composite_resource, new_folder)
    # add the the txt file to the resource at the above folder
    self.add_file_to_resource(file_to_add=self.generic_file, upload_folder=new_folder)
    # there should be one resource file
    self.assertEqual(self.composite_resource.files.all().count(), 1)
    res_file = self.composite_resource.files.first()
    # file has a folder
    self.assertEqual(res_file.file_folder, new_folder)
    # check that the resource file is not part of an aggregation
    self.assertEqual(res_file.has_logical_file, False)
    self.assertEqual(FileSetLogicalFile.objects.count(), 0)
    # set folder to fileset logical file type (aggregation)
    set_type_url = reverse('set_file_type_public', kwargs={"pk": self.composite_resource.short_id,
                                                           "file_path": "",
                                                           "hs_file_type": "FileSet"})
    self.client.post(set_type_url, data={"folder_path": new_folder})
    res_file = self.composite_resource.files.first()
    # file has the same folder
    self.assertEqual(res_file.file_folder, new_folder)
    self.assertEqual(res_file.logical_file_type_name, self.logical_file_type_name)
    self.assertEqual(FileSetLogicalFile.objects.count(), 1)
    # aggregation dataset name should be same as the folder name
    self.assertEqual(res_file.logical_file.dataset_name, new_folder)
    delete_agg_url = reverse('delete_aggregation_public', kwargs={"resource_id": self.composite_resource.short_id,
                                                                  "file_path": new_folder,
                                                                  "hs_file_type": "FileSetLogicalFile"})
    self.client.delete(delete_agg_url)
    self.assertEqual(FileSetLogicalFile.objects.count(), 0)
    self.assertEqual(self.composite_resource.files.all().count(), 0)
    self.composite_resource.delete()