<commit_before>#!/usr/bin/python

# mininet tests for FAUCET
#
# * must be run as root
# * you can run a specific test case only, by adding the class name of the test
#   case to the command. Eg ./faucet_mininet_test.py FaucetUntaggedIPv4RouteTest
#
# TODO:
#
# * bridge hardware OF switch for comparison with OVS

import os
import re
import shutil
import tempfile
import time
import unittest
from mininet.log import setLogLevel
from mininet.net import Mininet
from mininet.node import Controller
from mininet.node import Host
from mininet.topo import Topo
from mininet.util import dumpNodeConnections, pmonitor

FAUCET_DIR = '../src/ryu_faucet/org/onfsdn/faucet'

CONFIG_HEADER = '''
---
dp_id: 0x1
name: "faucet-1"
hardware: "Open vSwitch"
'''<commit_msg>Add note that we need mininet > 2.2.0.<commit_after>#!/usr/bin/python

# mininet tests for FAUCET
#
# * must be run as root
# * you can run a specific test case only, by adding the class name of the test
#   case to the command. Eg ./faucet_mininet_test.py FaucetUntaggedIPv4RouteTest
#
# TODO:
#
# * bridge hardware OF switch for comparison with OVS
#
# REQUIRES:
#
# mininet 2.2.0 or later (Ubuntu 14 ships with 2.1.0, which is not supported)
# use the "install from source" option from https://github.com/mininet/mininet/blob/master/INSTALL.
# suggest ./util/install.sh -n

import os
import re
import shutil
import tempfile
import time
import unittest
from mininet.log import setLogLevel
from mininet.net import Mininet
from mininet.node import Controller
from mininet.node import Host
from mininet.topo import Topo
from mininet.util import dumpNodeConnections, pmonitor

FAUCET_DIR = '../src/ryu_faucet/org/onfsdn/faucet'

CONFIG_HEADER = '''
---
dp_id: 0x1
name: "faucet-1"
hardware: "Open vSwitch"
'''
{'fraction_non_alphanumeric': 0.08900226757369614, 'fraction_numerical': 0.010770975056689343, 'mean_word_length': 4.348484848484849, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4911721', 'n_tokens_mistral': 612, 'n_tokens_neox': 594, 'n_words': 209}