 #   the specified behavior is independent of how it implemented.
 #                                             ~~ wikipedia  ###
 
-describe "Game COMMUNICATIONS PROTOCOL Specification v0.2 \n", ->
+describe "Game COMMUNICATIONS PROTOCOL Specification v0.3 \n", ->
 
   before (test) -> server.start test
   

  describe "HOSTING GAMES", () ->

    it "should allow any logged in player to host a game", (done) ->
      @anyplayer.emit 'host', { game: "my.game"}
      @lukas.on 'host', (msg) ->
        expect(msg.game).to.equal "my.game"
        expect(msg.host).to.equal "Anyname"

      setTimeout done, 58
 
    it "must inform about open hosted games that are already online", (done) ->
      @lukas.send 'state'
      @lukas.on 'state', (msg) ->
        expect(msg).to.deep.equal( {
          players: [  { player:  "Anyname",
                        game:    "my.game",
                        joined:  1,
                        max:     2 },
                      { player: "Lukas" },
                      { player: "Ananda"  } ],
          chat: [ { player: "Lukas", msg: "happy again :-)" } ],
          games_played: 0,
          msges_send: 42
        })

    it "should tell any host what other players want to join", (done) ->
      @anotherplayer.emit 'join', { host: "Anyname", game: "my.game" }
