Skip to content

Commit

Permalink
adds samples
Browse files Browse the repository at this point in the history
  • Loading branch information
rvflash committed Mar 4, 2019
1 parent 750d697 commit b2fd623
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions server_test.go
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
package tcp_test

import "testing"
import (
"testing"

func TestNew(t *testing.T) {
"github.com/rvflash/tcp"
)

func ExampleNew() {
srv := tcp.New()
srv.SYN(sleep)
// now runs it!
}

func TestDefault(t *testing.T) {

srv := tcp.Default()
srv.ACK(stumble)
// now runs it!
}

0 comments on commit b2fd623

Please sign in to comment.