mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
Port the unit tests from https://github.com/vercel/nft/tree/941be1cb3b9d38fbc99a8a6f07af568a64ed0f12/test/unit
52 lines
1.3 KiB
JavaScript
52 lines
1.3 KiB
JavaScript
'use strict'
|
|
;(() => {
|
|
var exports = {}
|
|
exports.id = 829
|
|
exports.ids = [829]
|
|
exports.modules = {
|
|
/***/ 354: /***/ (
|
|
__unused_webpack_module,
|
|
__webpack_exports__,
|
|
__webpack_require__
|
|
) => {
|
|
// ESM COMPAT FLAG
|
|
__webpack_require__.r(__webpack_exports__)
|
|
|
|
// EXPORTS
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
default: () => /* binding */ handler,
|
|
}) // CONCATENATED MODULE: external "fs/promises"
|
|
|
|
const promises_namespaceObject = require('fs/promises') // CONCATENATED MODULE: ./pages/api/users.ts
|
|
// Fake users data
|
|
const users = [
|
|
{
|
|
id: 1,
|
|
},
|
|
{
|
|
id: 2,
|
|
},
|
|
{
|
|
id: 3,
|
|
},
|
|
]
|
|
async function handler(_req, res) {
|
|
const hello = await (0, promises_namespaceObject.readFile)(
|
|
__dirname + '/hello.txt',
|
|
'utf-8'
|
|
)
|
|
return hello
|
|
}
|
|
|
|
/***/
|
|
},
|
|
}
|
|
// load runtime
|
|
var __webpack_require__ = require('./webpack-api-runtime.js')
|
|
__webpack_require__.C(exports)
|
|
var __webpack_exec__ = (moduleId) =>
|
|
__webpack_require__((__webpack_require__.s = moduleId))
|
|
var __webpack_exports__ = __webpack_exec__(354)
|
|
module.exports = __webpack_exports__
|
|
})()
|