Code Snippets

Two Tools for Sproutcore Testing

Here are two tools that can help test their Sproutcore functions in a controlled enviornment. More information can be found in this blog post.

Jasmine provides an environment to test.

it("Should see login pane", function() {

Simulo allows us to simulate a user action such as fill in a text field, or click a button. This comes in handy for testing logins or forms. Simulo does this by using selectors like CSS and jQuery.

it("Test login fields", function() {
  //get variables
  if (email != '') {
    App.signInViewController.set('email', '');
    Simulo.fillIn('.signin-username input', '');
  if (pass != '') {
    App.signInViewController.set('password', '');
    Simulo.fillIn('.signin-password input', 'p@ssw0rd');


Resource Tags: