Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

benchmark: skip test-benchmark-os on IBMi #50286

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion benchmark/os/uptime.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,21 @@
'use strict';

const os = require('os');
const common = require('../common.js');
const uptime = require('os').uptime;
const assert = require('assert');

const uptime = os.uptime;

const bench = common.createBenchmark(main, {
n: [1e5],
});

function main({ n }) {
if (os.type() === 'OS400') {
console.log('Skipping: os.uptime is not implemented on IBMi');
process.exit(0);
}
Comment on lines +14 to +17
Copy link
Member

@H4ad H4ad Oct 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is better to put outside main, on top of the file, just not to have any weird behavior.

But is not a blocker for me, so do it if you agree.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mhdawson can you move this to a similar position like in other fs benchmarks?


// Warm up.
const length = 1024;
const array = [];
Expand Down
3 changes: 0 additions & 3 deletions test/benchmark/benchmark.status
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,3 @@ prefix benchmark

[$arch==arm]

[$system==ibmi]
test-benchmark-os.js: SKIP