def test_assert_ops_in_graph(self):
    with self.test_session():
        constant_op.constant(['hello', 'taffy'], name='hello')
        test_util.assert_ops_in_graph({'hello': 'Const'}, ops.get_default_graph())
    self.assertRaises(ValueError, test_util.assert_ops_in_graph, {'bye': 'Const'}, ops.get_default_graph())
    self.assertRaises(ValueError, test_util.assert_ops_in_graph, {'hello': 'Variable'}, ops.get_default_graph())
def test_assert_ops_in_graph(self):
    with self.test_session():
        constant_op.constant(['hello', 'taffy'], name='hello')
        test_util.assert_ops_in_graph({'hello': 'Const'}, ops.get_default_graph())
    self.assertRaises(ValueError, test_util.assert_ops_in_graph, {'bye': 'Const'}, ops.get_default_graph())
    self.assertRaises(ValueError, test_util.assert_ops_in_graph, {'hello': 'Variable'}, ops.get_default_graph())