Skip to content

Commit 06194d4

Browse files
committed
chore: fix JavaScript lint errors (issue #10475)
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: passed - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent ddc8202 commit 06194d4

1 file changed

Lines changed: 23 additions & 6 deletions

File tree

lib/node_modules/@stdlib/blas/base/isamax/test/test.isamax.native.js

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,13 +66,13 @@ tape( 'the function finds the index of the element with the maximum absolute val
6666
idx = isamax( 4, x, 1 );
6767
t.strictEqual( idx, expected, 'returns expected value' );
6868

69-
x = new Float32Array( [
69+
x = new Float32Array([
7070
0.2, // 1
7171
-0.6, // 2
7272
0.3, // 3
7373
5.0,
7474
5.0
75-
] );
75+
]);
7676
expected = 1;
7777

7878
idx = isamax( 3, x, 1 );
@@ -86,11 +86,11 @@ tape( 'if provided an `N` parameter less than `1`, the function returns `-1`', o
8686
var idx;
8787
var x;
8888

89-
x = new Float32Array( [
89+
x = new Float32Array([
9090
1.0,
9191
2.0,
9292
3.0
93-
] );
93+
]);
9494
expected = -1;
9595

9696
idx = isamax( 0, x, 1 );
@@ -125,12 +125,29 @@ tape( 'the function supports specifying a negative stride', opts, function test(
125125
var idx;
126126
var x;
127127

128-
x = new Float32Array( [ 3.0, -4.0, 1.0, 15.0, 4.0, 3.0 ] );
128+
x = new Float32Array([ 3.0, -4.0, 1.0, 15.0, 4.0, 3.0 ]);
129129

130130
idx = isamax( x.length, x, -1 );
131131
t.strictEqual( idx, 2, 'returns expected value' );
132132

133-
x = new Float32Array( [ 3.0, 999.9, 999.9, -4.0, 999.9, 999.9, 1.0, 999.9, 999.9, 15.0, 999.9, 999.9, 4.0, 999.9, 999.9, 3.0 ] );
133+
x = new Float32Array([
134+
3.0,
135+
999.9,
136+
999.9,
137+
-4.0,
138+
999.9,
139+
999.9,
140+
1.0,
141+
999.9,
142+
999.9,
143+
15.0,
144+
999.9,
145+
999.9,
146+
4.0,
147+
999.9,
148+
999.9,
149+
3.0
150+
]);
134151
idx = isamax( 6, x, -3 );
135152
t.strictEqual( idx, 2, 'returns expected value' );
136153

0 commit comments

Comments
 (0)