package main

import (
	"encoding/json"
	"testing"
)

func TestMe(t *testing.T) {

	//cli := NewOAuth2Client()

	cli := NewOAuth2Client0817()

	me, err := cli.Me()

	if err != nil {
		t.Error(err)
	}

	t.Log("Me")

	meAsJson, err := json.Marshal(me)

	if err != nil {
		t.Error(err)
	}

	t.Log(string(meAsJson))

}

func TestCfg(t *testing.T) {

	cfg := Config{
		ApiKey:            "lVnj6Ox9HPcI4LwArSSYU7Pba",
		ApiKeySecrect:     "QMSnWG4QwyXWBVW2hQazzxhw9cSjd32CDfXGkg2DEaUUdscCRZ",
		AccessToken:       "1783145144700874752-TqHrsFUL20fEz4nz71yYlYVihkGmZn",
		AccessTokenSecret: "QDmtDfsiMigTJk1iqoyq8zCHNQJq5zCeC560NH9T5yUZl",
		Token:             "AAAAAAAAAAAAAAAAAAAAAEaPvQEAAAAAWDyrWaIbZHPYeg3ifnvXWdlylvs%3D7XFIO4y2HA0suNxLv570AsaIfmWD4x6XB64zHd9saEqVAhuTMq",
	}

	cfgAsJson, err := json.Marshal(cfg)

	if err != nil {
		t.Fatal(err)
	}

	t.Log(string(cfgAsJson))

}
