Пример #1
0
func TestCreatePusherInitializesMarshaller(t *testing.T) {
	theMarshaller := serialization.NewJsonMarshaller()
	result := CreatePusher(aAppId, aAppKey, aAppSecret, aPoster, theMarshaller)

	if result.marshaller != theMarshaller {
		t.Error("marshaller not initialized correctly")
	}
}
Пример #2
0
package gopusher

import (
	"github.com/pjvds/pusher-go-server/serialization"
)

var (
	aAppId      = "myappid"
	aAppKey     = "myappkey"
	aAppSecret  = "myappsecret"
	aPoster     = &NullPoster{}
	aMarshaller = serialization.NewJsonMarshaller()
)