New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@burstjs/util

Package Overview
Dependencies
Maintainers
2
Versions
52
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@burstjs/util - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

out/sumNQTStringToNumber.d.ts

3

CHANGELOG.md
# Change Log
All notable changes to this project will be documented in this file.
## 0.1.2
- added `sumNQTStringToNumber`
## 0.1.0-rc.3

@@ -5,0 +8,0 @@ - Timestamp conversion functions

6

package.json
{
"name": "@burstjs/util",
"version": "0.1.1",
"version": "0.1.2",
"description": "Useful utilities and tools for building Burstcoin applications",

@@ -40,3 +40,3 @@ "keywords": [

"devDependencies": {
"@types/jest": "^23.3.12"
"@types/jest": "^24.0.12"
},

@@ -57,3 +57,3 @@ "scripts": {

},
"gitHead": "5ce4a3e1353fc38227fedac8e562cfa2567e6930"
"gitHead": "9faca336766edb3bb7339aa9bd6822551a1db497"
}

@@ -38,43 +38,2 @@ import {convertNumberToNQTString} from '../convertNumberToNQTString';

describe('convertNQTStringToNumber', () => {
it('should convertNQTStringToNumber()', () => {
let burst = convertNQTStringToNumber('000000000');
expect(burst).toBe(0);
burst = convertNQTStringToNumber('12300000000');
expect(burst).toBe(123);
burst = convertNQTStringToNumber('-100000000');
expect(burst).toBe(-1);
burst = convertNQTStringToNumber('123000000');
expect(burst).toBe(1.23);
});
it('should fail convertNQTStringToNumber() on invalid input', () => {
try {
const nqt = convertNQTStringToNumber('');
expect(nqt).toBe('Expected exception');
} catch (e) {
expect(e.message).toBe('Invalid argument');
}
try {
const nqt = convertNQTStringToNumber(null);
expect(nqt).toBe('Expected exception');
} catch (e) {
expect(e.message).toBe('Invalid argument');
}
try {
const nqt = convertNQTStringToNumber(undefined);
expect(nqt).toBe('Expected exception');
} catch (e) {
expect(e.message).toBe('Invalid argument');
}
});
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc