Files
ipfs-bch-wallet-service/test/unit/mocks/use-cases/index.js
T

62 lines
866 B
JavaScript
Raw Normal View History

/*
Mocks for the use cases.
*/
2021-07-10 17:56:54 -07:00
/* eslint-disable */
2021-07-10 17:56:54 -07:00
class UserUseCaseMock {
async createUser(userObj) {
return {}
}
async getAllUsers() {
return true
}
async getUser(params) {
return true
}
async updateUser(existingUser, newData) {
return true
}
async deleteUser(user) {
return true
}
async authUser(login, passwd) {
return {
generateToken: () => {}
}
}
}
2025-01-15 17:59:09 -04:00
class UsageUseCaseMock {
async cleanUsage() {
return {}
}
async getRestSummary() {
return true
}
async getTopIps(params) {
return true
}
async getTopEndpoints(existingUser, newData) {
return true
}
}
2021-07-10 17:56:54 -07:00
class UseCasesMock {
constuctor(localConfig = {}) {
// this.user = new UserUseCaseMock(localConfig)
}
user = new UserUseCaseMock()
2025-01-15 17:59:09 -04:00
usage = new UsageUseCaseMock()
2021-07-10 17:56:54 -07:00
}
2022-09-08 08:58:39 -07:00
export default UseCasesMock;