Skip to content

Commit

Permalink
Fixed problems suggested by Travis
Browse files Browse the repository at this point in the history
  • Loading branch information
dcappellin committed Nov 12, 2015
1 parent d6ff5f5 commit b9536c1
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 6 deletions.
8 changes: 8 additions & 0 deletions bytebuffer/bytebuffer-tests.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/// <reference path="bytebuffer.d.ts" />

import ByteBuffer = require("bytebuffer");

var bb = new ByteBuffer()
.writeIString("Hello world!")
.flip();
console.log(bb.readIString()+" from bytebuffer.js");
12 changes: 6 additions & 6 deletions bytebuffer/bytebuffer.d.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// Type definitions for ByteBuffer.js 5.0.0
// Type definitions for bytebuffer.js 5.0.0
// Project: https://github.com/dcodeIO/bytebuffer.js
// Definitions by: SINTEF-9012 <http://github.com/SINTEF-9012>
// Definitions by: Denis Cappellin <http://github.com/cappellin>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
// Definitions by: SINTEF-9012 <http://github.com/SINTEF-9012>

/// <reference path="../long/long.d.ts" />
/// <reference path="long.d.ts" />

declare class ByteBuffer
{
Expand All @@ -26,7 +26,7 @@ declare class ByteBuffer
/**
* Default no assertions flag of false.
*/
static DEFAULT_NOASSERT
static DEFAULT_NOASSERT: boolean;

/**
* Little endian constant that can be used instead of its boolean value. Evaluates to true.
Expand All @@ -51,7 +51,7 @@ declare class ByteBuffer
/**
* Metrics representing number of UTF8 characters.Evaluates to 1.
*/
static METRICS_CHARS
static METRICS_CHARS: number;

/**
* ByteBuffer version.
Expand Down Expand Up @@ -286,7 +286,7 @@ declare class ByteBuffer
/**
* Prints debug information about this ByteBuffer's contents.
*/
printDebug( out?: ( string ) => void ): void;
printDebug( out?: ( text: string ) => void ): void;

/**
* Reads an 8bit signed integer. This is an alias of ByteBuffer#readInt8.
Expand Down
6 changes: 6 additions & 0 deletions bytebuffer/long-tests.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/// <reference path="long.d.ts" />

import Long = require("long");

var longVal = new Long(0xFFFFFFFF, 0x7FFFFFFF);
console.log(longVal.toString());

0 comments on commit b9536c1

Please sign in to comment.