old_contents: import unittest
  from IPython.parallel import Client
  from distarray.client import DistArrayContext
  
  
  class TestDistArrayContext(unittest.TestCase):
  
      def setUp(self):
          self.client = Client()
          self.dv = self.client[:]
  
      def test_create_DAC(self):
          '''Can we create a plain vanilla context?'''
          dac = DistArrayContext(self.dv)
          self.assertIs(dac.view, self.dv)
  
      def test_create_DAC_with_targets(self):
          '''Can we create a context with a subset of engines?'''
          dac = DistArrayContext(self.dv, targets=[0, 1])
          self.assertIs(dac.view, self.dv)
  
  
  if __name__ == '__main__':
      unittest.main(verbosity=2)
  
new_contents: import unittest
  import numpy as np
  from IPython.parallel import Client
  from distarray.client import DistArrayContext
  
  
  class TestDistArrayContext(unittest.TestCase):
  
      def setUp(self):
          self.client = Client()
          self.dv = self.client[:]
  
      def test_create_DAC(self):
          '''Can we create a plain vanilla context?'''
          dac = DistArrayContext(self.dv)
          self.assertIs(dac.view, self.dv)
  
      def test_create_DAC_with_targets(self):
          '''Can we create a context with a subset of engines?'''
          dac = DistArrayContext(self.dv, targets=[0, 1])
          self.assertIs(dac.view, self.dv)
  
  
  class TestDistArrayProxy(unittest.TestCase):
  
      def setUp(self):
          self.client = Client()
          self.dv = self.client[:]
          self.dac = DistArrayContext(self.dv)
  
          self.dap = self.dac.fromndarray(np.arange(100))
  
      def test_getitem(self):
          self.assertEqual(self.dap[55], 55)
  
  
  if __name__ == '__main__':
      unittest.main(verbosity=2)
  
subject: Add simple failing test for DistArrayProxy getitem.