Skip to content

Commit 603c766

Browse files
committed
test: only conditionally run tests
--- 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: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: passed - task: run_c_examples status: passed - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: passed - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: passed - task: run_c_benchmarks status: passed - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: passed - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: passed ---
1 parent 2712c2c commit 603c766

File tree

5 files changed

+16
-15
lines changed

5 files changed

+16
-15
lines changed

lib/node_modules/@stdlib/stats/base/dists/exponential/median/test/test.native.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ tape( 'if provided a rate parameter `lambda` that is not a nonnegative number, t
6666
t.end();
6767
});
6868

69-
tape( 'the function returns the median of an exponential distribution', function test( t ) {
69+
tape( 'the function returns the median of an exponential distribution', opts, function test( t ) {
7070
var expected;
7171
var lambda;
7272
var i;

lib/node_modules/@stdlib/stats/base/dists/normal/stdev/test/test.native.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,25 +38,28 @@ var data = require( './fixtures/python/data.json' );
3838
// VARIABLES //
3939

4040
var stdev = tryRequire( resolve( __dirname, './../lib/native.js' ) );
41+
var opts = {
42+
'skip': ( stdev instanceof Error )
43+
};
4144

4245

4346
// TESTS //
4447

45-
tape( 'main export is a function', function test( t ) {
48+
tape( 'main export is a function', opts, function test( t ) {
4649
t.ok( true, __filename );
4750
t.strictEqual( typeof stdev, 'function', 'main export is a function' );
4851
t.end();
4952
});
5053

51-
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) {
54+
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', opts, function test( t ) {
5255
var y = stdev( NaN, 1.0 );
5356
t.equal( isnan( y ), true, 'returns NaN' );
5457
y = stdev( 1.0, NaN );
5558
t.equal( isnan( y ), true, 'returns NaN' );
5659
t.end();
5760
});
5861

59-
tape( 'if provided a nonpositive `sigma`, the function returns `NaN`', function test( t ) {
62+
tape( 'if provided a nonpositive `sigma`, the function returns `NaN`', opts, function test( t ) {
6063
var y;
6164

6265
y = stdev( 2.0, 0.0 );
@@ -83,7 +86,7 @@ tape( 'if provided a nonpositive `sigma`, the function returns `NaN`', function
8386
t.end();
8487
});
8588

86-
tape( 'the function returns the standard deviation of a normal distribution', function test( t ) {
89+
tape( 'the function returns the standard deviation of a normal distribution', opts, function test( t ) {
8790
var expected;
8891
var delta;
8992
var sigma;

lib/node_modules/@stdlib/stats/base/dists/rayleigh/mean/test/test.native.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,7 @@ tape( 'if provided `NaN` for `sigma`, the function returns `NaN`', opts, functio
5555
});
5656

5757
tape( 'if provided a scale `sigma` that is not a nonnegative number, the function returns `NaN`', opts, function test( t ) {
58-
var mu;
59-
60-
mu = mean( -1.0 );
58+
var mu = mean( -1.0 );
6159
t.equal( isnan( mu ), true, 'returns NaN' );
6260

6361
mu = mean( NINF );
@@ -66,7 +64,7 @@ tape( 'if provided a scale `sigma` that is not a nonnegative number, the functio
6664
t.end();
6765
});
6866

69-
tape( 'the function returns the expected value of a Rayleigh distribution', function test( t ) {
67+
tape( 'the function returns the expected value of a Rayleigh distribution', opts, function test( t ) {
7068
var expected;
7169
var sigma;
7270
var i;

lib/node_modules/@stdlib/stats/base/dists/triangular/mean/test/test.native.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ var opts = {
4343

4444
// TESTS //
4545

46-
tape( 'main export is a function', function test( t ) {
46+
tape( 'main export is a function', opts, function test( t ) {
4747
t.ok( true, __filename );
4848
t.strictEqual( typeof mean, 'function', 'main export is a function' );
4949
t.end();
5050
});
5151

52-
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) {
52+
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', opts, function test( t ) {
5353
var v = mean( NaN, 1.0, 0.5 );
5454
t.equal( isnan( v ), true, 'returns NaN' );
5555

@@ -62,7 +62,7 @@ tape( 'if provided `NaN` for any parameter, the function returns `NaN`', functio
6262
t.end();
6363
});
6464

65-
tape( 'if provided parameters not satisfying `a <= c <= b`, the function returns `NaN`', function test( t ) {
65+
tape( 'if provided parameters not satisfying `a <= c <= b`, the function returns `NaN`', opts, function test( t ) {
6666
var y;
6767

6868
y = mean( -1.0, -1.1, -1.0 );

lib/node_modules/@stdlib/stats/base/dists/triangular/mode/test/test.native.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ var opts = {
4343

4444
// TESTS //
4545

46-
tape( 'main export is a function', function test( t ) {
46+
tape( 'main export is a function', opts, function test( t ) {
4747
t.ok( true, __filename );
4848
t.strictEqual( typeof mode, 'function', 'main export is a function' );
4949
t.end();
5050
});
5151

52-
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) {
52+
tape( 'if provided `NaN` for any parameter, the function returns `NaN`', opts, function test( t ) {
5353
var v = mode( NaN, 1.0, 0.5 );
5454
t.equal( isnan( v ), true, 'returns NaN' );
5555

@@ -62,7 +62,7 @@ tape( 'if provided `NaN` for any parameter, the function returns `NaN`', functio
6262
t.end();
6363
});
6464

65-
tape( 'if provided parameters not satisfying `a <= c <= b`, the function returns `NaN`', function test( t ) {
65+
tape( 'if provided parameters not satisfying `a <= c <= b`, the function returns `NaN`', opts, function test( t ) {
6666
var y;
6767

6868
y = mode( -1.0, -1.1, -1.0 );

0 commit comments

Comments
 (0)