From 40820b86f92ef7fed436b4416208dca86e3b1cbb Mon Sep 17 00:00:00 2001 From: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com> Date: Wed, 17 Jan 2024 05:14:40 +0000 Subject: [PATCH] Update artifacts --- array/base/any-by-right/coverage.ndjson | 1 + array/base/any-by-right/index.html | 2 +- array/base/any-by-right/index.js.html | 2 +- array/base/any-by-right/main.js.html | 2 +- array/base/any-by/coverage.ndjson | 1 + array/base/any-by/index.html | 2 +- array/base/any-by/index.js.html | 2 +- array/base/any-by/main.js.html | 2 +- array/base/any/coverage.ndjson | 1 + array/base/any/index.html | 2 +- array/base/any/index.js.html | 2 +- array/base/any/main.js.html | 2 +- array/base/assert/coverage.ndjson | 1 + .../assert/has-same-values/coverage.ndjson | 1 + array/base/assert/has-same-values/index.html | 131 ++++ .../base/assert/has-same-values/index.js.html | 214 ++++++ .../base/assert/has-same-values/main.js.html | 622 ++++++++++++++++++ array/base/assert/index.html | 10 +- array/base/assert/index.js.html | 35 +- array/base/every-by-right/coverage.ndjson | 1 + array/base/every-by-right/index.html | 2 +- array/base/every-by-right/index.js.html | 2 +- array/base/every-by-right/main.js.html | 2 +- array/base/every-by/coverage.ndjson | 1 + array/base/every-by/index.html | 2 +- array/base/every-by/index.js.html | 2 +- array/base/every-by/main.js.html | 2 +- array/base/every/coverage.ndjson | 1 + array/base/every/index.html | 2 +- array/base/every/index.js.html | 2 +- array/base/every/main.js.html | 2 +- array/base/none-by-right/coverage.ndjson | 1 + array/base/none-by-right/index.html | 2 +- array/base/none-by-right/index.js.html | 2 +- array/base/none-by-right/main.js.html | 2 +- array/base/none-by/coverage.ndjson | 1 + array/base/none-by/index.html | 2 +- array/base/none-by/index.js.html | 2 +- array/base/none-by/main.js.html | 2 +- array/base/none/coverage.ndjson | 1 + array/base/none/index.html | 2 +- array/base/none/index.js.html | 2 +- array/base/none/main.js.html | 2 +- 43 files changed, 1041 insertions(+), 36 deletions(-) create mode 100644 array/base/assert/has-same-values/coverage.ndjson create mode 100644 array/base/assert/has-same-values/index.html create mode 100644 array/base/assert/has-same-values/index.js.html create mode 100644 array/base/assert/has-same-values/main.js.html diff --git a/array/base/any-by-right/coverage.ndjson b/array/base/any-by-right/coverage.ndjson index e21ec2ddc..376bfb32f 100644 --- a/array/base/any-by-right/coverage.ndjson +++ b/array/base/any-by-right/coverage.ndjson @@ -1 +1,2 @@ [173,173,100,13,13,100,3,3,100,173,173,100,"81330b0935563655d3447f4d6c94843f991aea8e","2024-01-16 01:52:02 -0800"] +[173,173,100,13,13,100,3,3,100,173,173,100,"38194192104129d2e7078a7739af01d39a99e727","2024-01-16 21:11:50 -0800"] diff --git a/array/base/any-by-right/index.html b/array/base/any-by-right/index.html index 0077ed47e..c6368be6c 100644 --- a/array/base/any-by-right/index.html +++ b/array/base/any-by-right/index.html @@ -116,7 +116,7 @@

All files array/base/any-by-right/lib Code coverage generated by istanbul - at 2024-01-16T09:54:14.607Z + at 2024-01-17T05:14:10.381Z + + + + + + \ No newline at end of file diff --git a/array/base/assert/has-same-values/index.js.html b/array/base/assert/has-same-values/index.js.html new file mode 100644 index 000000000..7455430fb --- /dev/null +++ b/array/base/assert/has-same-values/index.js.html @@ -0,0 +1,214 @@ + + + + + + Code coverage report for array/base/assert/has-same-values/lib/index.js + + + + + + + + + +
+
+

All files / array/base/assert/has-same-values/lib index.js

+
+ +
+ 100% + Statements + 43/43 +
+ + +
+ 100% + Branches + 1/1 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 100% + Lines + 43/43 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +441x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x + 
/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 The Stdlib Authors.
+*
+* 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.
+*/
+ 
+'use strict';
+ 
+/**
+* Test if two arrays have the same values.
+*
+* @module @stdlib/array/base/assert/has-same-values
+*
+* @example
+* var hasSameValues = require( '@stdlib/array/base/assert/has-same-values' );
+*
+* var x = [ 0, 0, 1, 0 ];
+* var y = [ 0, 0, 1, 0 ];
+*
+* var out = hasSameValues( x, y );
+* // returns true
+*/
+ 
+// MODULES //
+ 
+var main = require( './main.js' );
+ 
+ 
+// EXPORTS //
+ 
+module.exports = main;
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/array/base/assert/has-same-values/main.js.html b/array/base/assert/has-same-values/main.js.html new file mode 100644 index 000000000..5b599100c --- /dev/null +++ b/array/base/assert/has-same-values/main.js.html @@ -0,0 +1,622 @@ + + + + + + Code coverage report for array/base/assert/has-same-values/lib/main.js + + + + + + + + + +
+
+

All files / array/base/assert/has-same-values/lib main.js

+
+ +
+ 100% + Statements + 179/179 +
+ + +
+ 100% + Branches + 23/23 +
+ + +
+ 100% + Functions + 3/3 +
+ + +
+ 100% + Lines + 179/179 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +1801x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +29x +29x +29x +58x +7x +7x +58x +22x +29x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +5x +5x +5x +5x +5x +5x +5x +5x +5x +5x +5x +5x +5x +5x +9x +1x +1x +9x +4x +5x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +1x +38x +38x +38x +38x +38x +38x +38x +38x +4x +4x +34x +34x +38x +15x +15x +15x +15x +5x +5x +15x +5x +5x +5x +15x +5x +5x +15x +5x +5x +5x +15x +10x +10x +5x +5x +19x +38x +1x +1x +1x +1x +1x + 
/**
+* @license Apache-2.0
+*
+* Copyright (c) 2024 The Stdlib Authors.
+*
+* 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.
+*/
+ 
+'use strict';
+ 
+// MODULES //
+ 
+var isComplex128Array = require( '@stdlib/array/base/assert/is-complex128array' );
+var isComplex64Array = require( '@stdlib/array/base/assert/is-complex64array' );
+var arraylike2object = require( '@stdlib/array/base/arraylike2object' );
+var reinterpret128 = require( '@stdlib/strided/base/reinterpret-complex128' );
+var reinterpret64 = require( '@stdlib/strided/base/reinterpret-complex64' );
+var isSameValue = require( '@stdlib/assert/is-same-value' );
+ 
+ 
+// FUNCTIONS //
+ 
+/**
+* Tests if two arrays have the same values.
+*
+* @private
+* @param {Collection} x - first input array
+* @param {Collection} y - second input array
+* @returns {boolean} boolean indicating if both arrays have the same values
+*
+* @example
+* var x = [ 0, 0, 1, 0 ];
+* var y = [ 0, 0, 1, 0 ];
+*
+* var out = internal( x, y );
+* // returns true
+*
+* @example
+* var x = [ 0, 0, 0, 0 ];
+* var y = [ 0, 0, 1, 0 ];
+*
+* var out = internal( x, y );
+* // returns false
+*/
+function internal( x, y ) {
+	var i;
+	for ( i = 0; i < x.length; i++ ) {
+		if ( !isSameValue( x[ i ], y[ i ] ) ) {
+			return false;
+		}
+	}
+	return true;
+}
+ 
+/**
+* Tests if two arrays have the same values.
+*
+* @private
+* @param {Object} x - first input array object
+* @param {Object} y - second input array object
+* @returns {boolean} boolean indicating if both arrays have the same values
+*
+* @example
+* var toAccessorArray = require( '@stdlib/array/base/to-accessor-array' );
+* var arraylike2object = require( '@stdlib/array/base/arraylike2object' );
+*
+* var x = arraylike2object( toAccessorArray( [ 0, 0, 1, 0 ] ) );
+* var y = arraylike2object( toAccessorArray( [ 0, 0, 1, 0 ] ) );
+*
+* var out = accessors( x, y );
+* // returns true
+*
+* @example
+* var toAccessorArray = require( '@stdlib/array/base/to-accessor-array' );
+* var arraylike2object = require( '@stdlib/array/base/arraylike2object' );
+*
+* var x = arraylike2object( toAccessorArray( [ 0, 0, 0, 0 ] ) );
+* var y = arraylike2object( toAccessorArray( [ 0, 0, 1, 0 ] ) );
+*
+* var out = accessors( x, y );
+* // returns false
+*/
+function accessors( x, y ) {
+	var xdata;
+	var ydata;
+	var xget;
+	var yget;
+	var i;
+ 
+	xdata = x.data;
+	ydata = y.data;
+ 
+	xget = x.accessors[ 0 ];
+	yget = y.accessors[ 0 ];
+ 
+	for ( i = 0; i < xdata.length; i++ ) {
+		if ( !isSameValue( xget( xdata, i ), yget( ydata, i ) ) ) {
+			return false;
+		}
+	}
+	return true;
+}
+ 
+ 
+// MAIN //
+ 
+/**
+* Tests if two arrays have the same values.
+*
+* @param {Collection} x - first input array
+* @param {Collection} y - second input array
+* @returns {boolean} boolean indicating if both arrays have the same values
+*
+* @example
+* var x = [ 0, 0, 1, 0 ];
+* var y = [ 0, 0, 1, 0 ];
+*
+* var out = hasSameValues( x, y );
+* // returns true
+*
+* @example
+* var x = [ 0, 0, 0, 0 ];
+* var y = [ 0, 0, 1, 0 ];
+*
+* var out = hasSameValues( x, y );
+* // returns false
+*/
+function hasSameValues( x, y ) {
+	var FLG;
+	var xo;
+	var yo;
+	var xr;
+	var yr;
+ 
+	if ( x.length !== y.length ) {
+		return false;
+	}
+	xo = arraylike2object( x );
+	yo = arraylike2object( y );
+	if ( xo.accessorProtocol || yo.accessorProtocol ) {
+		FLG = 2;
+ 
+		// If provided a complex number array, reinterpret as a real typed array and test interleaved real and imaginary components...
+		if ( isComplex128Array( x ) ) {
+			xr = reinterpret128( x, 0 );
+			FLG -= 1;
+		} else if ( isComplex64Array( x ) ) {
+			xr = reinterpret64( x, 0 );
+			FLG -= 1;
+		}
+		if ( isComplex128Array( y ) ) {
+			yr = reinterpret128( y, 0 );
+			FLG -= 1;
+		} else if ( isComplex64Array( y ) ) {
+			yr = reinterpret64( y, 0 );
+			FLG -= 1;
+		}
+		if ( FLG === 0 ) {
+			return internal( xr, yr );
+		}
+		return accessors( xo, yo );
+	}
+	return internal( x, y );
+}
+ 
+ 
+// EXPORTS //
+ 
+module.exports = hasSameValues;
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/array/base/assert/index.html b/array/base/assert/index.html index 920586dc4..3d7de4d12 100644 --- a/array/base/assert/index.html +++ b/array/base/assert/index.html @@ -25,7 +25,7 @@

All files array/base/assert/lib

100% Statements - 78/78 + 87/87
@@ -46,7 +46,7 @@

All files array/base/assert/lib

100% Lines - 78/78 + 87/87
@@ -84,13 +84,13 @@

All files array/base/assert/lib

100% - 78/78 + 87/87 100% 1/1 100% 0/0 100% - 78/78 + 87/87 @@ -101,7 +101,7 @@

All files array/base/assert/lib