Add integration test for view_models
fixed js script injection
incorporate review comments