code: def testPhantomEdge(self):
      e = self.g.es[self.g.ecount() - 1]
      e.delete()
  
      # v is now a phantom edge; try to freak igraph out now :)
      self.assertRaises(ValueError, e.update_attributes, a=2)
      self.assertRaises(ValueError, e.__getitem__, "a")
      self.assertRaises(ValueError, e.__setitem__, "a", 4)
      self.assertRaises(ValueError, e.__delitem__, "a")
      self.assertRaises(ValueError, e.attributes)
      self.assertRaises(ValueError, getattr, e, "source")
      self.assertRaises(ValueError, getattr, e, "source_vertex")
      self.assertRaises(ValueError, getattr, e, "target")
      self.assertRaises(ValueError, getattr, e, "target_vertex")
      self.assertRaises(ValueError, getattr, e, "tuple")
      self.assertRaises(ValueError, getattr, e, "vertex_tuple")
  
imports: import unittest
  from igraph import Graph, Edge, EdgeSeq, VertexSeq
  from .utils import is_pypy
label_desc: Use image node_id 6 for calling the EdgeTests obj's underlying member method code with example usage: obj.testPhantomEdge() without return types