File: mce_kill.t

package info (click to toggle)
liblinux-prctl-perl 1.5.0-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 368 kB
  • ctags: 768
  • sloc: perl: 166; ansic: 19; makefile: 2
file content (15 lines) | stat: -rw-r--r-- 464 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use strict;
no strict 'subs';
use warnings;

use Test::More tests => 7;
use Linux::Prctl qw(:constants :functions);

SKIP: {
    skip "set_mce_kill not available", 7 unless Linux::Prctl->can('set_mce_kill');
    is(get_mce_kill, MCE_KILL_DEFAULT, "Checking default mce_kill value");
    for(MCE_KILL_EARLY, MCE_KILL_LATE, MCE_KILL_DEFAULT) {
        is(set_mce_kill($_), 0, "Setting tsc to $_");
        is(get_mce_kill, $_, "Checking whether tsc is $_");
    }
}