Postie: category filter

I have a plugin that bind user to category (bind user to category). I’d like to integrate it, with postie filter.

So I made some test and I create a filter to insert received post into a category. This is my test function:
function auto_category($post){
$cat = {‘RugbyCS Test’};
$post[‘post_category’] = $cat;
return ($post);
}
add_filter(‘postie_post’, ‘auto_category’);

But after fetching email, that existing category is not set.
I tried also with the category_id (instead of category string) but it doesn’t work.