Add tests for Ajax functinality