def TestCaseSetup(tc): iterelem = tc.module.iterator.Get() tc.pvtdata.type = getattr(iterelem, 'type', None) tc.pvtdata.count = getattr(iterelem, 'count', 1) #tc.AddIgnorePacketField('TCP', 'sport') modcbs.TestCaseSetup(tc) return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) oiflist = tc.config.root.segment.floodlist.enic_list tc.pvtdata.pruned_oiflist = [] for oif in oiflist: if oif == tc.config.root.intf: continue tc.pvtdata.pruned_oiflist.append(oif) return
def TestCaseSetup(tc): tc.SetRetryEnabled(True) modcbs.TestCaseSetup(tc) oiflist = tc.config.src.segment.floodlist.enic_list tc.pvtdata.pruned_oiflist = [] for oif in oiflist: if oif == tc.config.src.endpoint.intf: continue tc.pvtdata.pruned_oiflist.append(oif) return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) tcp_proxy.SetupProxyArgs(tc) tcb1, tcb2 = get_tcbs(tc) tcp_proxy.init_flow_pvtdata(tc, tcb1, tcb2) return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) iterelem = tc.module.iterator.Get() if iterelem is not None: tc.pvtdata.count = getattr(iterelem, 'count', 1) if not tc.config.flow.IsMulticast(): return tc.pvtdata.fte_session_aware = False eniclist = tc.config.flow.GetMulticastEnicOifList() tc.pvtdata.pruned_oiflist = [] for oif in eniclist: if oif == tc.config.src.endpoint.intf: continue tc.pvtdata.pruned_oiflist.append(oif) return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) asp = tc.module.infra_data.ConfigStore.objects.Get('SEC_PROF_ACTIVE') iterelem = tc.module.iterator.Get() if iterelem is None: return pfname = getattr(iterelem, 'profile', None) if pfname is not None and tc.module.pvtdata.profile != pfname: profile = tc.module.infra_data.ConfigStore.objects.Get(pfname) logger.info("Updating Active Security Profile --> %s" % profile) asp.CloneFields(profile) asp.Update() tc.module.pvtdata.profile = pfname if pfname == 'SEC_PROF_TCP_RST_WITH_DATA_ACTION_EDIT': tc.AddIgnorePacketField('PADDING', 'data') return
def TestCaseSetup(tc): global cpurx_dpr global arq modcbs.TestCaseSetup(tc) id = 0 CpuCbHelper.main(id) # Clone objects that are needed for verification cpurx_dpr = copy.deepcopy( tc.infra_data.ConfigStore.objects.db["CPU_RX_DPR"]) cpurx_dpr.GetMeta() cpurx_dpr.GetRingEntries([cpurx_dpr.pi]) for i in range(3): arqid = ('CPU%04d_ARQ' % i) arq.insert(i, copy.deepcopy(tc.infra_data.ConfigStore.objects.db[arqid])) arq[i].GetMeta() return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) iterelem = tc.module.iterator.Get() tc.pvtdata.fte_session_aware = False tc.pvtdata.vlan_strip = getattr(iterelem, 'vlan_strip', False) tc.pvtdata.flood = getattr(iterelem, 'flood', False) if tc.pvtdata.flood == True: eniclist = tc.config.src.segment.floodlist.GetEnicOifList() else: eniclist = tc.config.flow.GetMulticastEnicOifList() tc.pvtdata.pruned_oiflist = [] for oif in eniclist: if oif == tc.config.src.endpoint.intf: continue tc.pvtdata.pruned_oiflist.append(oif) if tc.pvtdata.vlan_strip: oif.lif.vlan_strip_en = True oif.lif.Update() return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) iterelem = tc.module.iterator.Get() acl = tc.infra_data.ConfigStore.objects.Get(iterelem.id) tc.pvtdata.acl = acl tc.pvtdata.scenario = getattr(iterelem, 'scenario', None) if 'mirror' in iterelem.__dict__: tc.pvtdata.span_case = iterelem.mirror tc.config.ingress_mirror.session1 = acl.GetIngressMirrorSession(idx = 1) tc.config.ingress_mirror.session2 = acl.GetIngressMirrorSession(idx = 2) tc.config.ingress_mirror.session3 = acl.GetIngressMirrorSession(idx = 3) tc.config.egress_mirror.session1 = acl.GetEgressMirrorSession(idx = 1) tc.config.egress_mirror.session2 = acl.GetEgressMirrorSession(idx = 2) tc.config.egress_mirror.session3 = acl.GetEgressMirrorSession(idx = 3) # Update the ACL parameters based on the testcase acl.UpdateFromTCConfig(tc.config.flow, tc.config.src.endpoint, tc.config.dst.endpoint,\ tc.config.src.segment, tc.config.src.tenant) acl.Update() return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) tc.pvtdata.dhcp_server = (tc.config.root.segment.GetRemoteEps())[0] return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) lif = tc.config.dst.endpoint.intf.lif lif.vlan_strip_en = True lif.Update()
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) return
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) lif = tc.config.src.endpoint.intf.lif lif.vlan_insert_en = True lif.Update()
def TestCaseSetup(tc): modcbs.TestCaseSetup(tc) stepspec = tc.module.iterator.Get() tc.tracker.SetStep(stepspec, tc) tc.tracker.SetupTestcaseConfig(tc) return
def TestCaseSetup(tc): tc.SetRetryEnabled(True) modcbs.TestCaseSetup(tc) return
def TestCaseSetup(tc): tc.AddIgnorePacketField('UDP', 'sport') modcbs.TestCaseSetup(tc) return
def TestCaseSetup(tc): return modcbs.TestCaseSetup(tc)