Courses
Vue Foundations Vue Fullstack Vue Enterprise
Articles
Latest Topics
More
Newsletter Sponsorship Discord About
The video for this lesson is currently being updated, please read the transcript instead.
Vue Fullstack > Lesson 27

API test setup

In order to test our endpoints, we'll need to be able to interact with our Express server from our test spec files.

All our endpoints are part of our Express instance, so let's export this instance and then we can import it into our tests.

So at the bottom of our server file we can go:

server/index.js

module.exports = app;

Now our server file is actually a module.


Back to course page

Click to load comments...

Courses
  • Vue Foundations
  • Vue Fullstack
  • Vue Enterprise
Articles
  • Latest
  • Topics
Newsletter
  • Join
  • Sponsorship
More
  • Discord
  • Vue.js jobs
  • About

Vue.js Developers © 2021. View our privacy policy .

  • RSS
  • |
  • Atom