/*
 * Copyright (c) 2018, 2025, Oracle and/or its affiliates.
 * Licensed under The Universal Permissive License (UPL), Version 1.0
 * as shown at https://oss.oracle.com/licenses/upl/
 */
var Server=function(port,filebase){var Server=require("mock-http-server");this._filebase=filebase;this._server=new Server({host:"localhost",port:port||8135});this._setRoutes()};Server.prototype.start=function(cb){this._server.start(cb)};Server.prototype.stop=function(cb){this._server.stop(cb)};Server.prototype._setRoutes=function(){this._server.on({method:"GET",path:"/test",reply:{status:200,headers:{"content-type":"application/json"},body:JSON.stringify({"hello":"world"})}});this._server.on({method:"GET",path:"/",reply:{status:200,headers:{"content-type":"application/json"},body:JSON.stringify({"hello":"world"})}})};Server.prototype.getRequests=function(){return this._server.requests()};module.exports=Server;