implemented lifecycles
updated test app