コード例 #1
0
ファイル: test_services.py プロジェクト: jaunis/xivo-dao
    def test_find_all(self, profile_dao_find_all):
        profile1 = CtiProfile()
        profile2 = CtiProfile()
        profile_dao_find_all.return_value = [profile1, profile2]

        [res1, res2] = services.find_all()

        assert_that(res1, same_instance(profile1))
        assert_that(res2, same_instance(profile2))
コード例 #2
0
ファイル: actions.py プロジェクト: jlebleu/xivo-confd
def find_all():
    profiles = services.find_all()
    result = formatter.list_to_api(profiles)
    return make_response(result, 200)
コード例 #3
0
ファイル: actions.py プロジェクト: jaunis/xivo-restapi
def find_all():
    profiles = services.find_all()
    result = formatter.list_to_api(profiles)
    return make_response(result, 200)