scope changes, error testing