Skip to content
This repository has been archived by the owner on May 14, 2021. It is now read-only.

Commit

Permalink
Merge pull request #4 from kinecosystem/finalize-package
Browse files Browse the repository at this point in the history
kin-sdk porting completed
  • Loading branch information
bolshoy committed Jan 15, 2019
2 parents 726be36 + 0a50992 commit b0c1295
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 13 deletions.
17 changes: 13 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,19 @@ As this project is pre 1.0, breaking changes may happen for minor version bumps.

## 0.20.0

* **Breaking change** Changed naming and currency precision
Chaged native currency to have 5 decimal points instead of 7 in Stellar.
Changed naming from Stellar to Kin where applicable.
Updated dependencies.
* **Breaking change** Npm package name changed, added scoping.
* **Breaking change** Changed network passphrase.
* Changed naming from Stellar to Kin where applicable.
* Updated dependencies.
* Updated docs.

## 0.11.0

* **Breaking change** Native currency precision changed from 7 decimals to 5.
* Fixed circular dependency.
* Updated dependencies.
* Updated docs.
* Fixed Travis build.

## 0.10.0

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ This is an implementation in JavaScript that can be used on either Node.js or we

Using npm to include js-kin-base in your own project:
```shell
npm install --save kin-base
npm install --save @kinecosystem/kin-base
```

For browsers, [use Bower to install it](#to-use-in-the-browser). It exports a
Expand All @@ -41,7 +41,7 @@ relative to your html file.
1. Install it using npm:

```shell
npm install --save kin-base
npm install --save @kinecosystem/kin-base
```
2. require/import it in your JavaScript:

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "kin-base",
"version": "0.11.0",
"name": "@kinecosystem/kin-base",
"version": "0.20.0",
"description": "Low level Kin support library",
"main": "lib/index.js",
"scripts": {
Expand Down
8 changes: 4 additions & 4 deletions src/network.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ import {hash} from "./hashing";

/**
* Contains passphrases for common networks:
* * `Networks.PUBLIC`: `Public Global Stellar Network ; September 2015`
* * `Networks.TESTNET`: `Test SDF Network ; September 2015`
* * `Networks.PUBLIC`: `Kin Mainnet ; December 2018`
* * `Networks.TESTNET`: `Kin Testnet ; December 2018`
* @type {{PUBLIC: string, TESTNET: string}}
*/
export const Networks = {
PUBLIC: "Public Global Stellar Network ; September 2015",
TESTNET: "Test SDF Network ; September 2015"
PUBLIC: "Kin Mainnet ; December 2018",
TESTNET: "Kin Testnet ; December 2018"
};

var current = null;
Expand Down
2 changes: 1 addition & 1 deletion test/unit/transaction_envelope_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe('TransactionEnvelope', function() {
let xdr = "AAAAAAtjwtJadppTmm0NtAU99BFxXXfzPO1N/SqR43Z8aXqXAAAAZAAIj6YAAAACAAAAAAAAAAEAAAAB0QAAAAAAAAEAAAAAAAAAAQAAAADLa6390PDAqg3qDLpshQxS+uVw3ytSgKRirQcInPWt1QAAAAAAAAAAA1Z+AAAAAAAAAAABfGl6lwAAAEBC655+8Izq54MIZrXTVF/E1ycHgQWpVcBD+LFkuOjjJd995u/7wM8sFqQqambL0/ME2FTOtxMO65B9i3eAIu4P";
var tx = new KinBase.Transaction(xdr);
KinBase.Network.usePublicNetwork();
expect(tx.hash().toString('hex')).to.be.equal("a84d534b3742ad89413bdbf259e02fa4c5d039123769e9bcc63616f723a2bcd5");
expect(tx.hash().toString('hex')).to.be.equal("8e4545df2cca9f09de22cfea8067342d4702e6899c6a0ecdf0fb2cec2c260a5a");
})

});

0 comments on commit b0c1295

Please sign in to comment.