Skip to content

jaysonhurd/polygon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Polygon experimentation

Background

Polygon is a neat company that ties into financial markets and meters usage to the rest of us. Some of it is free. This repository does not do anything particularly practical with Polygon since its REST API and SDK do it all so well. It is simply for practice.

Summary

This repository has packages that call Polygon in 3 different ways:

Package Location
REST pkg/rest
SDK pkg/sdk
WebSockets pkg/websocket

Running tests

Use the Makefile to run make test

 make test
go test -cover -v ./...
?       github.com/jaysonhurd/polygon/pkg/polygon       [no test files]
        github.com/jaysonhurd/polygon           coverage: 0.0% of statements
        github.com/jaysonhurd/polygon/pkg/polygon/polygonfakes          coverage: 0.0% of statements
=== RUN   TestNew
--- PASS: TestNew (0.00s)
=== RUN   Test_rest_PreviousCloseSuccess
--- PASS: Test_rest_PreviousCloseSuccess (0.00s)
=== RUN   Test_rest_PreviousCloseFailToGet
--- PASS: Test_rest_PreviousCloseFailToGet (0.00s)
=== RUN   Test_rest_PreviousCloseFailToReadBody
--- PASS: Test_rest_PreviousCloseFailToReadBody (0.00s)
=== RUN   Test_rest_PreviousCloseFailHttpRequestCreation
--- PASS: Test_rest_PreviousCloseFailHttpRequestCreation (0.00s)
=== RUN   Test_rest_StockPriceNowSuccess
--- PASS: Test_rest_StockPriceNowSuccess (0.00s)
=== RUN   Test_rest_StockPriceNowFailToGet
--- PASS: Test_rest_StockPriceNowFailToGet (0.00s)
=== RUN   Test_rest_StockPriceNowFailToReadBody
--- PASS: Test_rest_StockPriceNowFailToReadBody (0.00s)
=== RUN   Test_rest_StockPriceNowFailHttpRequestCreation
--- PASS: Test_rest_StockPriceNowFailHttpRequestCreation (0.00s)
PASS
coverage: 100.0% of statements
ok      github.com/jaysonhurd/polygon/pkg/rest  (cached)        coverage: 100.0% of statements
?       github.com/jaysonhurd/polygon/pkg/websocket     [no test files]
?       github.com/jaysonhurd/polygon/pkg/sdk   [no test files]

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published