示例#1
0
 def test_set_bounds(self):
     index = (3, 3)
     b_cell = Cell(index, self.mesh_params)
     b_cell.bounds('x_max', 'refl')
     eq_(b_cell.bounds('x_max'), 'refl')
示例#2
0
 def test_boundaries(self):
     for param in [('x_max', (3, 1)), ('y_max', (2, 3)), ('x_min', (0, 2)),
                   ('y_min', (3, 0))]:
         b_cell = Cell(param[1], self.mesh_params)
         ok_(param[0] in b_cell.bounds())
示例#3
0
 def test_multiple_bounds(self):
     index = (3, 3)
     b_cell = Cell(index, self.mesh_params)
     ok_('y_max' in b_cell.bounds() and 'x_max' in b_cell.bounds())
示例#4
0
 def test_is_boundary(self):
     for index in [(3, 1), (2, 3), (0, 2), (3, 0)]:
         b_cell = Cell(index, self.mesh_params)
         ok_(b_cell.bounds(), "boundary cell")