Skip to content

scarrington76/reddit_challenge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

reddit_challenge

Environment setup

You need to have Go, installed on your computer.

Verify the required tools by running the following commands:

go version

A Reddit API token is necessary to run the application and must be loaded into the env variables under the var name ACCESS_TOKEN

By default, the r/AskReddit thread will be tracked

Start in development mode

Navigate to the main folder and start the back end:

cd main
go run main.go

The back end will serve on http://localhost:8080.

Unit Testing

Unit tests can also be ran in the application from /main

A Reddit API token is necessary to run unit tests. The token string must be populated into the tok variable in main/server/test/test.go

cd main
go test ./...

Postman

A postman collection is provided in /postman to hit the endpoints to obtain user/post statistics. Simply import the collection into postman as a collection.

About

Reddit challenge for take-home

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages