Change ValueError to AssertionError