@dxos/keys
Advanced tools
Comparing version
{ | ||
"name": "@dxos/keys", | ||
"version": "0.1.13", | ||
"version": "0.1.14", | ||
"description": "Key utils and definitions.", | ||
@@ -9,8 +9,7 @@ "homepage": "https://dxos.org", | ||
"author": "DXOS.org", | ||
"main": "dist/src/index.js", | ||
"main": "dist/lib/node/index.cjs", | ||
"browser": { | ||
"node:assert": "assert", | ||
"node:util": "util" | ||
"./dist/lib/node/index.cjs": "./dist/lib/browser/index.mjs" | ||
}, | ||
"types": "dist/src/index.d.ts", | ||
"types": "dist/types/src/index.d.ts", | ||
"files": [ | ||
@@ -21,6 +20,5 @@ "dist", | ||
"dependencies": { | ||
"assert": "^2.0.0", | ||
"randombytes": "^2.1.0", | ||
"util": "^0.12.4", | ||
"@dxos/debug": "0.1.13" | ||
"@dxos/debug": "0.1.14", | ||
"@dxos/node-std": "0.1.14" | ||
}, | ||
@@ -27,0 +25,0 @@ "devDependencies": { |
@@ -7,2 +7,4 @@ // | ||
import { describe, test } from '@dxos/test'; | ||
import { PublicKey } from './public-key'; | ||
@@ -12,4 +14,4 @@ | ||
describe('PublicKey', function () { | ||
it('Basic key operations', function () { | ||
describe('PublicKey', () => { | ||
test('Basic key operations', () => { | ||
const publicKey = PublicKey.random().toString(); | ||
@@ -19,3 +21,3 @@ expect(PublicKey.stringify(PublicKey.bufferize(publicKey))).to.equal(publicKey); | ||
it('formatting', function () { | ||
test('formatting', () => { | ||
const key = PublicKey.fromHex(TEST_KEY_HEX); | ||
@@ -28,3 +30,3 @@ | ||
it('asBuffer', function () { | ||
test('asBuffer', () => { | ||
const key = PublicKey.fromHex(TEST_KEY_HEX); | ||
@@ -37,3 +39,3 @@ const buffer = key.asBuffer(); | ||
it('asUint8Array', function () { | ||
test('asUint8Array', () => { | ||
const key = PublicKey.fromHex(TEST_KEY_HEX); | ||
@@ -47,3 +49,3 @@ | ||
it('from', function () { | ||
test('from', () => { | ||
expect(PublicKey.from(TEST_KEY_HEX).toHex()).to.equal(TEST_KEY_HEX); | ||
@@ -58,3 +60,3 @@ | ||
it('equals', function () { | ||
test('equals', () => { | ||
expect(PublicKey.equals(PublicKey.from(TEST_KEY_HEX), PublicKey.from(TEST_KEY_HEX))).to.equal(true); | ||
@@ -65,3 +67,3 @@ | ||
it('expect equality', function () { | ||
test('expect equality', () => { | ||
const key = PublicKey.random(); | ||
@@ -68,0 +70,0 @@ expect(PublicKey.equals(key, PublicKey.from(key.toHex()))).to.be.true; |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
51758
45.75%3
-25%793
14.6%21
-8.7%1
Infinity%+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
Updated