diff --git a/lib/index.js b/lib/index.js index ec2a0e6b..fb4c7128 100644 --- a/lib/index.js +++ b/lib/index.js @@ -31,7 +31,7 @@ if (typeof Realm != 'undefined') { // eslint-disable-next-line } else if (typeof process == 'object' && ('' + process) == '[object process]') { // Prevent React Native packager from seeing this module. - const bindings = 'bindings'; + var bindings = 'bindings'; realmConstructor = require(bindings)('realm').Realm; } else { throw new Error('Missing Realm constructor - please ensure RealmReact framework is included!'); diff --git a/tests/index.js b/tests/index.js index 48455ea8..2db13ab2 100644 --- a/tests/index.js +++ b/tests/index.js @@ -1,3 +1,24 @@ +//////////////////////////////////////////////////////////////////////////// +// +// Copyright 2016 Realm Inc. +// +// Licensed 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. +// +//////////////////////////////////////////////////////////////////////////// + +/* eslint-env es6, node */ +/* eslint-disable no-console */ + 'use strict'; const mockery = require('mockery'); @@ -7,8 +28,6 @@ function runTests() { const testNames = RealmTests.getTestNames(); for (let suiteName in testNames) { - let testSuite = RealmTests[suiteName]; - console.log('Starting ' + suiteName); for (let testName of testNames[suiteName]) { diff --git a/tests/react-test-app/tests/index.js b/tests/react-test-app/tests/index.js index f40b104a..4e4e8aaa 100644 --- a/tests/react-test-app/tests/index.js +++ b/tests/react-test-app/tests/index.js @@ -19,7 +19,6 @@ 'use strict'; const React = require('react-native'); -const Realm = require('realm'); const RealmTests = require('realm-tests'); RealmTests.registerTests({ @@ -56,8 +55,6 @@ function runTests() { let testNames = RealmTests.getTestNames(); for (let suiteName in testNames) { - let testSuite = RealmTests[suiteName]; - console.log('Starting ' + suiteName); for (let testName of testNames[suiteName]) {