Commit Diff


commit - 1927dcedd3c9f75fc546db4395a7422c9b9abcbf
commit + 345979a989141d7ce01fe1cd0ffde2a62b3d1955
blob - ae4e3de52c695ef444cb57999b53bfedb27b6c46
blob + cf99bf554849b5269a22bb8205f63ffb41c481c1
--- .cirrus.yml
+++ .cirrus.yml
@@ -19,7 +19,7 @@ ubuntu_1804_gcc: &ubuntu_1804_gcc
     - apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 1E9377A2BA9EF27F
     - apt-get update
   install_script:
-    - apt-get install -y cmake gcc-9 g++-9 libc-dev build-essential fuse libfuse-dev mandoc python-pytest
+    - apt-get install -y cmake gcc-9 g++-9 libc-dev build-essential fuse libfuse-dev mandoc python-pytest fio
 
 ubuntu_1804_clang: &ubuntu_1804_clang
   <<: *ubuntu_1804
@@ -37,7 +37,7 @@ ubuntu_1804_clang: &ubuntu_1804_clang
     - apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 15CF4D18AF4F7421
     - apt-get update
   install_script:
-    - apt-get install -y cmake clang-${CLANG_VERSION} libc-dev build-essential fuse libfuse-dev mandoc python-pytest
+    - apt-get install -y cmake clang-${CLANG_VERSION} libc-dev build-essential fuse libfuse-dev mandoc python-pytest fio
     - update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${CLANG_VERSION} 10
 
 macos_1015: &macos_1015
@@ -47,7 +47,7 @@ macos_1015: &macos_1015
     CC: clang
   install_script:
     - brew install --cask osxfuse
-    - brew install cmake python3
+    - brew install cmake python3 fio
     - sudo python3 -m pip install pytest
 
 macos_1101: &macos_1101
@@ -57,7 +57,7 @@ macos_1101: &macos_1101
     - brew update-reset
     - brew upgrade
     - brew install --cask osxfuse
-    - brew install cmake python3
+    - brew install cmake python3 fio
     - sudo python3 -m pip install pytest
 
 freebsd_12_2: &freebsd_12_2
@@ -66,7 +66,7 @@ freebsd_12_2: &freebsd_12_2
   env:
     CC: clang
   install_script:
-    - ASSUME_ALWAYS_YES=yes pkg bootstrap -f; pkg install -y cmake fusefs-libs pkgconf python3 py37-pip
+    - ASSUME_ALWAYS_YES=yes pkg bootstrap -f; pkg install -y cmake fusefs-libs pkgconf python3 py37-pip fio
     - kldload fuse
     - kldstat
     - sudo python3.7 -m pip install pytest
blob - 953cc3ef724158e8e9497f972af2ee6b7efab4b2
blob + b758f3fa627bd4fdfc8673c01b1241a6a66afe25
--- tests/test_unreliablefs.py
+++ tests/test_unreliablefs.py
@@ -563,3 +563,18 @@ def test_fsx(setup_unreliablefs):
     os_create(mnt_name)
     cmd_line = '{} -N 10000 -d -W -c 4 {}'.format(fsx_bin, mnt_name)
     subprocess.check_call(cmd_line.split(' '))
+
+@pytest.mark.long
+def test_fio(setup_unreliablefs):
+    if not shutil.which('fio'):
+        pytest.skip('fio is required to execute testcase')
+
+    mnt_dir, src_dir = setup_unreliablefs
+    name = name_generator()
+    src_name = pjoin(src_dir, name)
+    mnt_name = pjoin(mnt_dir, name)
+    os_create(mnt_name)
+    cmd_line = "fio --name=random-write --ioengine=sync --rw=randwrite " \
+                "--bs=1m --size=1G --numjobs=1 --iodepth=1 --runtime=60 " \
+                "--time_based --end_fsync=1 --filename={}".format(mnt_name)
+    subprocess.check_call(cmd_line.split(' '))