Archive for the ‘Test’ Category

AngularJS CheatSheet

ng-app (usually on html)

ng-controller (on the body or on the container)

‘use strict’;

scripts order: Jquery – Angular (in the head possibly) other scripts: 

var testApp = angular.module(‘myFirstAng’, []);
testApp.controller(‘myController’, function ($scope) {
$scope.Test = “hello world”;


use of $http:

myApp.controller(‘myController’, function ($scope, $http) {

dataType: ‘json’, headers: {
“Content-Type”: “application/json”
}, data: ”, method: ‘GET’,
url: ‘/api/Sdb’
}).success(function (data, status, headers, config) {
$scope.Result = data;
.error(function (data, status, headers, config) {


NG-Repeat: ng-repeat=”friend in friends”


data-ng-options=”bg.Name for bg in businessGroups”
data-ng-change=”ChangeEvent()” >
<option value=””>-Select-</option>



 <div class=“gridStyle” ng-grid=“gridOptions” style=“width: 90%; height: 90%”></div>


 $scope.gridOptions = {
                data: ‘users’, columnDefs: [
                    { field: ‘FullName’, displayName: ‘FullName’, resizable:true, width:200 },
                    { field: ‘UserName’, displayName: ‘UserName’, resizable: true },
                        field: ‘LastLogin’, displayName: ‘LastLogin’,
                        cellFilter: “date:’dd/MM/yyyy HH:mm'”
                    { field: ‘AssignedRoles’, displayName: ‘AssignedRoles’, resizable: true, cellFilter: ‘stringArrayFilter’ }]
                            function (dataReturned) {
                                $scope.users = dataReturned;

Jasmine testing:
describe("myApp", function() {
    describe("SimpleController", function() {
        var scope;
        beforeEach(inject(function($rootScope, $controller) {
            scope = $rootScope.$new();
            $controller("SimpleController", {
                $scope: scope
        it("should double the numbers", function() {
Categories: DEV, Test Tags: ,

Mocking Azure TableStorage

Categories: DEV, Test Tags: ,

how to run a VS 2010 web test from command line

you need to have installed VS 2010 go in the VS 2010 prompt and run:

mstest /TestContainer:WebTest1.webtest

Categories: Test Tags: ,

WebUi test with powerShell

As you already know, I am a fan of WebUI test… some time you do not have a test framework and you need to run your test in the powerShell context…

this article will explain how to do it Smile

Categories: Test Tags: , ,

testing framework for Web UI

When it comes to web UI testing, you have several choices:

WebAii Telerik ( )

or VS (I would recommend it only on specific scenario…)
Categories: Test Tags: