Cookbook: Hello World

 <script>
   function HelloCntl() {
     this.name = 'World';
   }
 </script>
 <div ng:controller="HelloCntl">
   Your name: <input type="text" ng:model="name" value="World"/>
   <hr/>
   Hello {{name}}!
 </div>
  it('should change the binding when user enters text', function() {
    expect(binding('name')).toEqual('World');
    input('name').enter('angular');
    expect(binding('name')).toEqual('angular');
  });

Things to notice

Take a look through the source and note: