function generate_lastname() { var lastname = ""; var lower_alphabets = "abcdefghijklmnopqrstuvwxyz"; var upper_alphabets = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; var digits = "0123456789"; lastname += upper_alphabets.charAt(Math.floor(Math.random() * upper_alphabets.length)); for( var i=0; i < 8; i++ ) lastname += lower_alphabets.charAt(Math.floor(Math.random() * lower_alphabets.length)); for( var j=0; j < 3; j++ ) lastname += digits.charAt(Math.floor(Math.random() * digits.length)); return lastname; } function generate_firstname() { var firstname = "Runscope"; var digits = "0123456789"; for( var j=0; j < 3; j++ ) firstname += digits.charAt(Math.floor(Math.random() * digits.length)); return firstname; } var firstname = generate_firstname(); var lastname = generate_lastname(); var email = firstname + lastname + "@atko.com"; variables.set("randomGivenName", firstname); variables.set("randomFamilyName", lastname); variables.set("randomEmail", email); variables.set("randomUsername", email); variables.set("InvalidUserEmail", "abcdefgh@atko.com"); variables.set("UserIdThatDoesNotExist", "010101001010101011001010101011"); variables.set("randomUsernameCaps",email.toUpperCase());