🔘Go

If your functional tests are written in Go, you can use pynt command to run API Security tests from these functional tests.

Here is an example: test_goat.go is a go based tester for goat (our vulnerable application) that we use to test the functionality of goat, here is how to run it:

  1. Get test_goat.go

curl https://raw.githubusercontent.com/pynt-io/pynt/main/goat_functional_tests/goat_test.go -o goat_test.go
  1. Get testify

go get github.com/stretchr/testify
  1. go mod

go mod init goat_test.go
go mod tidy
  1. Check that functional test works

go test
  1. Run Pynt on functional test

pynt command --cmd "go test"

Last updated