Fixed scoping tests