added assertions to methods and variables