mock resource when defining style