FeaturesTemplatesShowcaseTownie
AI
BlogDocsPricing
Log inSign up
std
stdtest
Public
Like
test
Home
Code
1
README.md
Branches
1
Pull requests
Remixes
History
Environment variables
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in miliseconds.
Sign up now
Code
/
Code
/
Search
README.md

test

This project is currently under development.

Val Town should have a standard way to write tests. The idea behind this project is to create such a standard test framework for Val Town.

So far I have two prototypes:

  1. In secret_scanner
  2. In glide_omni

Both are fine. Both have the tests as JSON (name, input, output). There are two differences:

  1. The first test uses lodash's isEqual and the second uses expect from Deno's std library
  2. The first outputs to an HTML page in an HTTP val, the second logs to the console

Probably expect is the right tool for the job.

The main issues with them are:

  1. It would be nice to have better standard test syntax (ie it and describe). Maybe such a library could work here or maybe I could build it in this project.
  2. I'd love the ability to run the tests on every save. Or configurable on any action. Eventually, we'll want to run tests on pull requests, ie before merging. Maybe project-wide logs will help. Maybe configuring cmd+enter will help.

Also: would be neat if I could run tests in an interactive mode that would let me save the new "snapshots".

Jackson has an awesome prototype that includes a badge you can include in readmes, and it will rerun the tests whenever the badge is loaded: https://www.val.town/v/jxnblk/test

Code
README.md
Go to top
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Product
FeaturesPricing
Developers
DocsStatusAPI ExamplesNPM Package Examples
Explore
ShowcaseTemplatesNewest ValsTrending ValsNewsletter
Company
AboutBlogCareersBrandhi@val.town
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.