Form3 Take Home Exercise
This is a solution to Form3 Take Home Exercise done by Maksim Shcherbo aka screwyprof.
import "github.com/screwyprof/form3api"Create a new Client instance, then call the corresponding methods to get what you want, for example:
c := form3api.NewClient(nil, "http://localhost:8080/v1")
accountID := "51646a03-a52e-4e51-b405-cf2b8078c1a8"
acc, err := c.FetchAccount(context.Background(), form3api.FetchAccount{AccountID: accountID})Take a look at Client Demo for more details.
To run tests in docker use make test-docker, or its equivalent docker-compose up --build --abort-on-container-exit
This document guides your though the steps I've taken to implement this library. Each step is represented by a separate Github Issue.
High-level decisions on the project architecture are captured in the following ADR.md document.
Simply run make or make all to install all the required dependencies and tools, to run linters and all the tests.
Use make help to get information about additional targets.
To run unit and E2E tests run make test. To run unit tests only make test-unit. To run E2E tests make test-e2e
Install the linters by running make tools. This step is required once only. To run linters use make lint.
Use make fmt to run go fmt