diff --git a/lib/nodets/Makefile.am b/lib/nodets/Makefile.am
index ea640cf..939dff2 100755
--- a/lib/nodets/Makefile.am
+++ b/lib/nodets/Makefile.am
@@ -20,6 +20,7 @@
 stubs: $(top_srcdir)/test/ThriftTest.thrift
 	mkdir -p test-compiled
 	$(THRIFT) --gen js:node,ts -o test/ $(top_srcdir)/test/ThriftTest.thrift && $(THRIFT) --gen js:node,ts -o test-compiled $(top_srcdir)/test/ThriftTest.thrift
+	$(THRIFT) --gen js:node,ts -o test/ $(top_srcdir)/test/Int64Test.thrift && $(THRIFT) --gen js:node,ts -o test-compiled $(top_srcdir)/test/Int64Test.thrift
 
 ts-compile: stubs
 	mkdir -p test-compiled
diff --git a/lib/nodets/test/int64.test.ts b/lib/nodets/test/int64.test.ts
new file mode 100644
index 0000000..3ff0d85
--- /dev/null
+++ b/lib/nodets/test/int64.test.ts
@@ -0,0 +1,81 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import Int64 = require("node-int64");
+import i64types = require("./gen-nodejs/Int64Test_types");
+import test = require("tape");
+
+const cases = {
+  "should correctly generate Int64 constants": function(assert) {
+    const EXPECTED_SMALL_INT64_AS_NUMBER: number = 42;
+    const EXPECTED_SMALL_INT64: Int64 = new Int64(42);
+    const EXPECTED_MAX_JS_SAFE_INT64: Int64 = new Int64(Number.MAX_SAFE_INTEGER);
+    const EXPECTED_MIN_JS_SAFE_INT64: Int64 = new Int64(Number.MIN_SAFE_INTEGER);
+    const EXPECTED_MAX_JS_SAFE_PLUS_ONE_INT64: Int64 = new Int64("0020000000000000"); // hex-encoded
+    const EXPECTED_MIN_JS_SAFE_MINUS_ONE_INT64: Int64 = new Int64("ffe0000000000000"); // hex-encoded 2's complement
+    const EXPECTED_MAX_SIGNED_INT64: Int64 = new Int64("7fffffffffffffff"); // hex-encoded
+    const EXPECTED_MIN_SIGNED_INT64: Int64 = new Int64("8000000000000000"); // hex-encoded 2's complement
+    const EXPECTED_INT64_LIST: Int64[] = [
+      EXPECTED_SMALL_INT64,
+      EXPECTED_MAX_JS_SAFE_INT64,
+      EXPECTED_MIN_JS_SAFE_INT64,
+      EXPECTED_MAX_JS_SAFE_PLUS_ONE_INT64,
+      EXPECTED_MIN_JS_SAFE_MINUS_ONE_INT64,
+      EXPECTED_MAX_SIGNED_INT64,
+      EXPECTED_MIN_SIGNED_INT64
+    ];
+
+    assert.ok(EXPECTED_SMALL_INT64.equals(i64types.SMALL_INT64));
+    assert.ok(EXPECTED_MAX_JS_SAFE_INT64.equals(i64types.MAX_JS_SAFE_INT64));
+    assert.ok(EXPECTED_MIN_JS_SAFE_INT64.equals(i64types.MIN_JS_SAFE_INT64));
+    assert.ok(
+      EXPECTED_MAX_JS_SAFE_PLUS_ONE_INT64.equals(
+        i64types.MAX_JS_SAFE_PLUS_ONE_INT64
+      )
+    );
+    assert.ok(
+      EXPECTED_MIN_JS_SAFE_MINUS_ONE_INT64.equals(
+        i64types.MIN_JS_SAFE_MINUS_ONE_INT64
+      )
+    );
+    assert.ok(EXPECTED_MAX_SIGNED_INT64.equals(i64types.MAX_SIGNED_INT64));
+    assert.ok(EXPECTED_MIN_SIGNED_INT64.equals(i64types.MIN_SIGNED_INT64));
+    assert.equal(
+      EXPECTED_SMALL_INT64_AS_NUMBER,
+      i64types.SMALL_INT64.toNumber()
+    );
+    assert.equal(
+      Number.MAX_SAFE_INTEGER,
+      i64types.MAX_JS_SAFE_INT64.toNumber()
+    );
+    assert.equal(
+      Number.MIN_SAFE_INTEGER,
+      i64types.MIN_JS_SAFE_INT64.toNumber()
+    );
+
+    for (let i = 0; i < EXPECTED_INT64_LIST.length; ++i) {
+      assert.ok(EXPECTED_INT64_LIST[i].equals(i64types.INT64_LIST[i]));
+    }
+    assert.end();
+  }
+};
+
+Object.keys(cases).forEach(function(caseName) {
+  test(caseName, cases[caseName]);
+});
diff --git a/lib/nodets/test/test-cases.ts b/lib/nodets/test/test-cases.ts
index ca740ec..44f254e 100644
--- a/lib/nodets/test/test-cases.ts
+++ b/lib/nodets/test/test-cases.ts
@@ -1,6 +1,7 @@
 'use strict';
 
 import ttypes = require('./gen-nodejs/ThriftTest_types');
+import Int64 = require('node-int64');
 
 //all Languages in UTF-8
 /*jshint -W100 */
@@ -84,7 +85,7 @@
   string_thing: 'Zero',
   byte_thing: 1,
   i32_thing: -3,
-  i64_thing: 1000000
+  i64_thing: new Int64(1000000)
 });
 
 export var out2 = new ttypes.Xtruct2();
@@ -93,17 +94,17 @@
 out2.i32_thing = 5;
 
 export var crazy = new ttypes.Insanity({
-  "userMap":{ "5":5, "8":8 },
+  "userMap":{ "5":new Int64(5), "8":new Int64(8) },
   "xtructs":[new ttypes.Xtruct({
       "string_thing":"Goodbye4",
       "byte_thing":4,
       "i32_thing":4,
-      "i64_thing":4
+      "i64_thing":new Int64(4)
     }), new ttypes.Xtruct({
       "string_thing":"Hello2",
       "byte_thing":2,
       "i32_thing":2,
-      "i64_thing":2
+      "i64_thing":new Int64(2)
     })]
 });
 
diff --git a/lib/nodets/test/testAll.sh b/lib/nodets/test/testAll.sh
index a7c00bf..3be12c3 100755
--- a/lib/nodets/test/testAll.sh
+++ b/lib/nodets/test/testAll.sh
@@ -11,7 +11,9 @@
 {
   #generating thrift code
   ${DIR}/../../../compiler/cpp/thrift -o ${DIR} --gen js:node,ts ${DIR}/../../../test/ThriftTest.thrift
+  ${DIR}/../../../compiler/cpp/thrift -o ${DIR} --gen js:node,ts ${DIR}/../../../test/Int64Test.thrift
   ${DIR}/../../../compiler/cpp/thrift -o ${COMPILEDDIR} --gen js:node,ts ${DIR}/../../../test/ThriftTest.thrift
+  ${DIR}/../../../compiler/cpp/thrift -o ${COMPILEDDIR} --gen js:node,ts ${DIR}/../../../test/Int64Test.thrift
 
   tsc --outDir $COMPILEDDIR --project $DIR/tsconfig.json
 }
@@ -30,6 +32,8 @@
   return $RET
 }
 
+node ${COMPILEDDIR}/int64.test.js || TESTOK=1
+
 #integration tests
 
 testServer || TESTOK=1
diff --git a/lib/nodets/test/test_handler.ts b/lib/nodets/test/test_handler.ts
index 1bc855a..996c32a 100644
--- a/lib/nodets/test/test_handler.ts
+++ b/lib/nodets/test/test_handler.ts
@@ -24,6 +24,7 @@
 import thrift = require("thrift");
 import Thrift = thrift.Thrift;
 import Q = require("q");
+import Int64 = require("node-int64");
 
 
 export class SyncThriftTestHandler {
@@ -62,7 +63,7 @@
 
     return Q.resolve(insane);
   }
-  testMulti(arg0: any, arg1: number, arg2: number, arg3: { [k: number]: string; }, arg4: ttypes.Numberz, arg5: number) {
+  testMulti(arg0: any, arg1: number, arg2: Int64, arg3: { [k: number]: string; }, arg4: ttypes.Numberz, arg5: number) {
     var hello = new ttypes.Xtruct();
     hello.string_thing = 'Hello2';
     hello.byte_thing = arg0;
@@ -196,7 +197,7 @@
     }
     return Q.resolve();
   }
-  testMulti(arg0: any, arg1: number, arg2: number, arg3: { [k: number]: string; }, arg4: ttypes.Numberz, arg5: number, result: Function): Q.IPromise<ttypes.Xtruct> {
+  testMulti(arg0: any, arg1: number, arg2: Int64, arg3: { [k: number]: string; }, arg4: ttypes.Numberz, arg5: number, result: Function): Q.IPromise<ttypes.Xtruct> {
     var hello = this.syncHandler.testMulti(arg0, arg1, arg2, arg3, arg4, arg5);
     hello.then(hello => result(null, hello));
     return Q.resolve();
