code: def test_rating_metric(self):
      metric = RatingMetric()
  
      self.assertEqual(metric.type, "rating")
      self.assertIsNone(metric.name)
  
      try:
          metric.compute()
      except NotImplementedError:
          assert True
  
file_path: cornac/tests/cornac/metrics/test_rating.py
imports: import unittest
  import numpy
  from cornac.metrics.rating import RatingMetric
  from cornac.metrics import RMSE
  from cornac.metrics import MAE
  from cornac.metrics import MSE
label_desc: Use image node_id 1 for calling the TestRating obj's underlying member method code with example usage: obj.test_rating_metric() without return types