Projects
Mega:24.03
nodejs-concat-stream
_service:tar_scm:nodejs-concat-stream-typedarra...
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:nodejs-concat-stream-typedarray.patch of Package nodejs-concat-stream
commit 845a8c5172bbab80b2af72e3a73d1ccf14477a2e Author: Tom Hughes <tom@compton.nu> Date: Sun Jan 17 16:37:10 2016 +0000 Only require typedarray if necessary diff --git a/test/buffer.js b/test/buffer.js index d28f5f9..fa7127f 100644 --- a/test/buffer.js +++ b/test/buffer.js @@ -1,7 +1,11 @@ var concat = require('../') var test = require('tape') -var TA = require('typedarray') -var U8 = typeof Uint8Array !== 'undefined' ? Uint8Array : TA.Uint8Array + +if (typeof Uint8Array === 'undefined') { + var U8 = require('typedarray').Uint8Array +} else { + var U8 = Uint8Array +} test('buffer stream', function (t) { t.plan(2) diff --git a/test/string.js b/test/string.js index 218c522..29001f4 100644 --- a/test/string.js +++ b/test/string.js @@ -1,7 +1,11 @@ var concat = require('../') var test = require('tape') -var TA = require('typedarray') -var U8 = typeof Uint8Array !== 'undefined' ? Uint8Array : TA.Uint8Array + +if (typeof Uint8Array === 'undefined') { + var U8 = require('typedarray').Uint8Array +} else { + var U8 = Uint8Array +} test('string -> buffer stream', function (t) { t.plan(2) diff --git a/test/typedarray.js b/test/typedarray.js index ee07110..fffda88 100644 --- a/test/typedarray.js +++ b/test/typedarray.js @@ -1,7 +1,11 @@ var concat = require('../') var test = require('tape') -var TA = require('typedarray') -var U8 = typeof Uint8Array !== 'undefined' ? Uint8Array : TA.Uint8Array + +if (typeof Uint8Array === 'undefined') { + var U8 = require('typedarray').Uint8Array +} else { + var U8 = Uint8Array +} test('typed array stream', function (t) { t.plan(2)
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2