Skip to content
This repository has been archived by the owner on Mar 11, 2024. It is now read-only.

Commit

Permalink
Add unit test for ChannelData.URI() (#43)
Browse files Browse the repository at this point in the history
* Add ID field to User struct

Also make sure it's filled in the appropriate places. This allows you to add
some granularity to whom can run certain commands.

Fixes #39
  • Loading branch information
doenietzomoeilijk authored and fabioxgn committed Feb 22, 2017
1 parent e614e12 commit c149929
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions cmd_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,3 +289,16 @@ func TestMessageReceived(t *testing.T) {
})
})
}

func TestChannelData(t *testing.T) {
Convey("Given a ChannelData struct", t, func() {
Convey("Make sure ChannelData can give you the Channel URI", func() {
cd := ChannelData{
Protocol: "irc",
Server: "myserver",
Channel: "#mychan",
}
So(cd.URI(), ShouldEqual, "irc://myserver/#mychan")
})
})
}

0 comments on commit c149929

Please sign in to comment.