code: def test_ranker(self):
      testing_utils.train_model(
          {
              "task": "integration_tests",
              "model": "transformer/ranker",
              "candidates": "batch",
              "model_parallel": True,
              **MODEL_OPTS,
          }
      )
  
      with self.assertRaises(RuntimeError):
          testing_utils.train_model(
              {
                  "task": "integration_tests",
                  "model": "transformer/ranker",
                  "data_parallel": True,
                  "model_parallel": True,
                  "candidates": "batch",
                  **MODEL_OPTS,
              }
          )
  
file_path: ParlAI/tests/test_multigpu.py
imports: import unittest
  import parlai.utils.testing
label_desc: Use image node_id 2 for calling the TestModelParallel obj's underlying member method code with example usage: obj.test_ranker() without return types