Fix view test case setup