added tests and cart behavior