File: error_constants_test.py

package info (click to toggle)
pycurl 7.45.7-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,752 kB
  • sloc: python: 8,663; ansic: 6,891; makefile: 202; sh: 183
file content (25 lines) | stat: -rw-r--r-- 662 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vi:ts=4:et

import pycurl
import unittest

from . import util

class ErrorConstantsTest(unittest.TestCase):
    @util.min_libcurl(7, 21, 5)
    def test_not_built_in(self):
        assert hasattr(pycurl, 'E_NOT_BUILT_IN')
    
    @util.min_libcurl(7, 24, 0)
    def test_ftp_accept_failed(self):
        assert hasattr(pycurl, 'E_FTP_ACCEPT_FAILED')
    
    @util.min_libcurl(7, 21, 5)
    def test_unknown_option(self):
        assert hasattr(pycurl, 'E_UNKNOWN_OPTION')
    
    @util.min_libcurl(7, 39, 0)
    def test_pinnedpubkeynotmatch(self):
        assert hasattr(pycurl, 'E_SSL_PINNEDPUBKEYNOTMATCH')