-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore : update files to js & npm test
- Loading branch information
1 parent
06086b2
commit 9b4ed31
Showing
10 changed files
with
63 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,7 @@ | ||
const Hajar = require("../src/index").default; | ||
const { hajar } = require("../www/src/@sikka/hajar/index"); | ||
|
||
// Replace with actual tests | ||
describe("Hajar.src.js", () => { | ||
it("should get the library's version", () => { | ||
expect(Hajar.version).toEqual("1.0.41"); | ||
}); | ||
|
||
it("should get the library's name", () => { | ||
const name = Hajar._name; | ||
expect(name).toEqual("Hajar"); | ||
expect(hajar.version).toEqual("1.0.41"); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
const login = require("./login"); | ||
|
||
// @TODO add register function here | ||
module.exports = { | ||
login, | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
class HajarError extends Error { | ||
constructor(message, slug, customProperties) { | ||
super(message); | ||
this.slug = slug; | ||
if (customProperties) { | ||
Object.assign(this, customProperties); | ||
} | ||
} | ||
} | ||
|
||
module.exports = HajarError; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// index.js | ||
/* const auth = require("./core/auth"); */ | ||
const initHajar = require("./core/init.js"); | ||
|
||
const hajar = { | ||
/* auth: auth, */ | ||
initHajar, | ||
version: "1.0.41", | ||
}; | ||
|
||
module.exports = { hajar }; |
This file was deleted.
Oops, something went wrong.