mirror of
https://github.com/oceanprotocol-archive/squid-js.git
synced 2024-02-02 15:31:51 +01:00
Remove OceanBase.
This commit is contained in:
parent
7394e7ddec
commit
780475b35f
@ -4,14 +4,23 @@ import Keeper from "../keeper/Keeper"
|
||||
import Web3Provider from "../keeper/Web3Provider"
|
||||
import Balance from "../models/Balance"
|
||||
import Logger from "../utils/Logger"
|
||||
import OceanBase from "./OceanBase"
|
||||
|
||||
/**
|
||||
* Account information.
|
||||
*/
|
||||
export default class Account extends OceanBase {
|
||||
export default class Account {
|
||||
private password?: string
|
||||
|
||||
constructor(private id: string = "0x0") { }
|
||||
|
||||
public getId() {
|
||||
return this.id
|
||||
}
|
||||
|
||||
public setId(id) {
|
||||
this.id = id
|
||||
}
|
||||
|
||||
/**
|
||||
* Set account password.
|
||||
* @param {string} password Password for account.
|
||||
|
@ -1,18 +0,0 @@
|
||||
export default abstract class OceanBase {
|
||||
|
||||
protected id = "0x00"
|
||||
|
||||
constructor(id?) {
|
||||
if (id) {
|
||||
this.id = id
|
||||
}
|
||||
}
|
||||
|
||||
public getId() {
|
||||
return this.id
|
||||
}
|
||||
|
||||
public setId(id) {
|
||||
this.id = id
|
||||
}
|
||||
}
|
@ -1,4 +0,0 @@
|
||||
import OceanBase from "../../src/ocean/OceanBase"
|
||||
|
||||
export default class OceanBaseMock extends OceanBase {
|
||||
}
|
@ -1,30 +0,0 @@
|
||||
import {assert} from "chai"
|
||||
import OceanBaseMock from "../mocks/OceanBase.Mock"
|
||||
|
||||
describe("OceanBase", () => {
|
||||
|
||||
describe("#getId()", () => {
|
||||
|
||||
it("should get the id", async () => {
|
||||
|
||||
const id = "test"
|
||||
const oceanBase = new OceanBaseMock(id)
|
||||
|
||||
assert(oceanBase.getId() === id)
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
describe("#setId()", () => {
|
||||
|
||||
it("should get the id", async () => {
|
||||
|
||||
const id = "test"
|
||||
const oceanBase = new OceanBaseMock()
|
||||
oceanBase.setId(id)
|
||||
|
||||
assert(oceanBase.getId() === id)
|
||||
})
|
||||
})
|
||||
|
||||
})
|
Loading…
Reference in New Issue
Block a user