Compare commits

...

No commits in common. "c8-stream-1_fileformat_v6" and "stream-pmdk-1_fileformat_v6-rhel-8.9.0" have entirely different histories.

7 changed files with 41 additions and 2 deletions

0
.gitignore vendored
View File

View File

6
gating.yaml Normal file
View File

@ -0,0 +1,6 @@
--- !Policy
product_versions:
- rhel-8
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: baseos-ci.redhat-module.tier0.functional}

View File

@ -21,9 +21,9 @@ data:
rpms:
pmdk:
rationale: main pmdk library
ref: stream-rhel-8.8.0
ref: stream-pmdk-1_fileformat_v6-rhel-8.9.0
buildorder: 0
libpmemobj-cpp:
rationale: depends on (recent version of) pmdk
ref: stream-rhel-8.8.0
ref: stream-pmdk-1_fileformat_v6-rhel-8.9.0
buildorder: 10

15
tests/is_pmem.c Normal file
View File

@ -0,0 +1,15 @@
#include <libpmem.h>
#include <unistd.h>
#include <fcntl.h>
int
main(int argc, char **argv)
{
void *addr;
addr = pmem_map_file(argv[1], getpagesize(),
PMEM_FILE_CREATE, S_IWUSR|S_IRUSR, NULL, NULL);
if (addr)
return 0;
return -1;
}

6
tests/run_test.sh Executable file
View File

@ -0,0 +1,6 @@
#!/bin/bash
gcc -o is_pmem is_pmem.c -lpmem || exit 1
RET=$(./is_pmem ./testfile)
unlink testfile
exit $RET

12
tests/tests.yml Normal file
View File

@ -0,0 +1,12 @@
- hosts: localhost
roles:
- role: standard-test-basic
tags:
- classic
required_packages:
- libpmem-devel
- gcc
tests:
- simple:
dir: .
run: ./run_test.sh