Comments (5)
~> #2303
from nitro.
@pi0 Does this mean all tools for testing are existing but not documented?
- Is there a function to setup the Nitro app for tests?
- Are there fetch functions?
- How can I mock something like database connection or auth sessions?
The first two I currently implemented myself by looking at this repository: https://github.com/johannschopplich/nitro-starter/tree/main/test thanks to @johannschopplich
from nitro.
I have a plan to work on a branding new testing system for Nitro server which i need to better explain later once more shaped idea but in the meantime any setup that works for you. Setup function in shared repo seems nice 👍🏼
from nitro.
Sounds good! Possibly for v3?
from nitro.
For the record: I've built nitro-test-utils until the official utilities are ready. 🙂
from nitro.
Related Issues (20)
- Task cli forces .nitro as buildDir
- defineLazyEventHandler is not defined HOT 1
- Default node preset should let you set keepAliveTimeout & headersTimeout HOT 1
- defineRouteMeta not working with imported values
- Nuxt3 fails to build with preset when serverFunctionName is set HOT 1
- SSG doesn't work with routeRules on aws amlipify
- Support reproducible builds using `SOURCE_DATE_EPOCH`
- Run tasks single time even in cluster mode + max instances HOT 2
- Heroku deployments hanging
- 500 error on invalid paths for cached event handlers
- Nitro adds trailing slash at the end of devProxy target HOT 2
- Start Hook HOT 2
- [useStorage] getItem and getItemRaw -> Inconsistent behaviour between dev and preview/production HOT 1
- Provide a way to terminate websocket connections HOT 1
- Support route rules per HTTP verb HOT 1
- Azure preset Cannot find module HOT 1
- waitUntil not working in cloudflare pages preset
- Unable to dynamically add a driver for a storage named `cache` in a plugin HOT 1
- Unable to use fetch API on Azure Static web apps
- Route rules by method, specially for proxy requests HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nitro.