'Checks that GetSession and ReleaseSession are called in order.'

def testGetSessionReleaseSession(self):

    test_name = 'get-session-release-session'
    with tf.Graph().as_default():
        (builder, target) = self.getBuilderAndTarget(test_name)
        train = builder.add_training_from_config(target)
        anno = builder.add_annotation(test_name)
        path = _find_input_path_to_type(train['run'], 'foo')
        self.assertEmpty(path)
        self.checkOpOrder('train', train['run'], ['GetSession', 'ReleaseSession'])
        self.checkOpOrder('annotations', anno['annotations'], ['GetSession', 'ReleaseSession'])
