campaigns: Split up Store tests into separate functions with own dependencies
Created by: mrnugget
This fixes https://github.com/sourcegraph/sourcegraph/issues/10022 by splitting up the sub tests into their own functions.
I introduced some type definitions and helpers to reduce duplication and make it easier to write tests.