Skip to content

Commit

Permalink
BCDA-7488: Add single test information (#147)
Browse files Browse the repository at this point in the history
## 🎫 Ticket

https://jira.cms.gov/browse/BCDA-7488

## 🛠 Changes

Added information to the README on running single tests.

## ℹ️ Context for reviewers

N/A

## ✅ Acceptance Validation

Confirmed proper formatting for content added via this PR in the README.

## 🔒 Security Implications

- [ ] This PR adds a new software dependency or dependencies.
- [ ] This PR modifies or invalidates one or more of our security
controls.
- [ ] This PR stores or transmits data that was not stored or
transmitted before.
- [ ] This PR requires additional review of its security implications
for other reasons.

If any security implications apply, add Jason Ashbaugh (GitHub username:
StewGoin) as a reviewer and do not merge this PR without his approval.

Co-authored-by: Alex Dzeda <[email protected]>
  • Loading branch information
alex-dzeda and alex-dzeda authored Dec 11, 2023
1 parent bde4582 commit de98544
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,13 @@ Note that to initialize our docker container, we use migrate-and-start, which co
The SSAS can be tested by running `make unit-test`. You can also use the repo-wide command `make test`, which will run tests against the entire repo, including the SSAS code. Some tests are designed to be only run as needed, and are excluded from `make` by a build tag. To include
one of these test suites, follow the instructions at the top of the test file.

### **Running Single / Single-file Unit Tests**

This step assumes that the user has installed VSCode, the Go language extension available [here](https://marketplace.visualstudio.com/items?itemName=golang.Go), and has successfully imported test data to their local database.

To run tests from within VSCode:
In a FILENAME_test.go file, there will be a green arrow to the left of the method name, and clicking this arrow will run a single test locally. Tests should not be dependent upon other tests, but if a known-good test is failing, the user can run all tests in a given file by going to View -> Command Palette -> Go: Test Package, which will run all tests in a given file. Alternatively, in some instances, the init() method can be commented out to enable testing of single functions.

# Integration Testing

To run postman tests locally:
Expand Down

0 comments on commit de98544

Please sign in to comment.