code: def test_rlock_acquire_release_count(tmpfile):
      lock = portalocker.RLock(tmpfile)
      # Twice acquire
      h = lock.acquire()
      assert not h.closed
      lock.acquire()
      assert not h.closed
  
      # Two release
      lock.release()
      assert not h.closed
      lock.release()
      assert h.closed
  
imports: from __future__ import print_function
  from __future__ import with_statement
  import os
  import dataclasses
  import multiprocessing
  import time
  import typing
  import pytest
  import portalocker
  from portalocker import utils
  from portalocker import LockFlags
label_desc: Use image node_id 10 for calling a global function with example usage: test_rlock_acquire_release_count(tmpfile) without return types