lin
2025-08-01 633231e833e21d5b8b1c00cb15aedb62b3b78e8f
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
environment:
 
  # Python versions that will be tested
  # Note: it defines variables that can be used later
  matrix:
    - PYTHON: "C:\\Python27-x64"
      PYTHON_VERSION: "2.7.x"
      PYTHON_ARCH: "64"
    - PYTHON: "C:\\Python36-x64"
      PYTHON_VERSION: "3.6.x"
      PYTHON_ARCH: "64"
 
# There is no build phase for Scapy
build: off
 
install:
  # Install the npcap, windump and wireshark suites
  - ps: .\.appveyor\InstallNpcap.ps1
  - ps: .\.appveyor\InstallWindump.ps1
  - choco install -y wireshark
  # Install Python modules
  - "%PYTHON%\\python -m pip install cryptography coverage mock"
  - set PATH="%PYTHON%\\Scripts\\;%PATH%"
 
test_script:
  # Set environment variables
  - set PYTHONPATH=%APPVEYOR_BUILD_FOLDER%
  - set PATH="%APPVEYOR_BUILD_FOLDER%;C:\Program Files\Wireshark\;%PATH%"
 
  # Disable open_ssl client tests
  - set ARGS=-K open_ssl_client
  # Disable broken Python 3 tests if Python3 is detected
  - if not x%PYTHON:3=%==x%PYTHON% set ARGS=%ARGS% -K FIXME_py3
  
  # Main unit tests
  - "%PYTHON%\\python -m coverage run --parallel-mode bin\\UTscapy -f text -t test\\regression.uts -F -K mock_read_routes6_bsd -K ipv6 || exit /b 42"
  - 'del test\regression.uts'
 
  # Secondary and contrib unit tests
  - 'del test\bpf.uts test\linux.uts test\sendsniff.uts' # Don't bother with OS dependent regression tests
  - "%PYTHON%\\python -m coverage run --parallel-mode bin\\UTscapy -c test\\configs\\windows.utsc %ARGS% || exit /b 42"
  
  # TLS unit tests
  # Note: due to a multiprocessing bug, we got to be in the UTscapy.py folder and call it directly
  - 'cd scapy/tools'
  - "%PYTHON%\\python -m coverage run --concurrency=multiprocessing UTscapy.py -f text -t ..\\..\\test\\tls\\tests_tls_netaccess.uts -F -P \"sys.path.append(os.path.abspath('../../test/tls'))\" %ARGS% || exit /b 42"
  - 'cd ../../'
 
after_test:
  # Install & run codecov
  - "%PYTHON%\\python -m pip install codecov"
  - "SET PATH=%PYTHON%\\Scripts\\;%PATH%"
  - "coverage combine ./"
  - codecov