Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(45)  |  Call(25)  |  Derive(0)  |  Import(20)

src/e/o/Eos-HEAD/tests/restriction_tracker/restrictions/test_implant_index.py   Eos(Download)
from eos.const.eos import Location, Restriction, State
from eos.const.eve import Attribute
from eos.fit.holder.item import Implant, ModuleHigh
from eos.tests.restriction_tracker.restriction_testcase import RestrictionTestCase
 
    def test_fail(self):
        # Check that if 2 or more holders are put into single slot
        # index, error is raised
        item = self.ch.type_(type_id=1, attributes={Attribute.implantness: 120})
        holder1 = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))
        holder2 = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))
    def test_fail_original(self):
        # Make sure that original attributes are used
        item = self.ch.type_(type_id=1, attributes={Attribute.implantness: 120})
        holder1 = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))
        holder2 = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_powergrid.py   Eos(Download)
from eos.const.eos import Location, State
from eos.const.eve import Attribute
from eos.fit.holder.item import ModuleHigh, Ship, Implant
from eos.tests.stat_tracker.stat_testcase import StatTestCase
 
        holder1.attributes = {Attribute.power: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.character, spec_set=Implant(1))
        holder2.attributes = {Attribute.power: 30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_cpu.py   Eos(Download)
from eos.const.eos import Location, State
from eos.const.eve import Attribute
from eos.fit.holder.item import ModuleHigh, Ship, Implant
from eos.tests.stat_tracker.stat_testcase import StatTestCase
 
        holder1.attributes = {Attribute.cpu: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.character, spec_set=Implant(1))
        holder2.attributes = {Attribute.cpu: 30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_drone_bandwidth.py   Eos(Download)
from eos.const.eos import Location, State
from eos.const.eve import Attribute
from eos.fit.holder.item import Drone, Ship, Implant
from eos.tests.stat_tracker.stat_testcase import StatTestCase
 
        holder1.attributes = {Attribute.drone_bandwidth_used: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.character, spec_set=Implant(1))
        holder2.attributes = {Attribute.drone_bandwidth_used: 30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/restriction_tracker/restrictions/test_drone_group.py   Eos(Download)
from eos.const.eos import Location, Restriction, State
from eos.const.eve import Attribute
from eos.fit.holder.item import Drone, Ship, Implant
from eos.tests.restriction_tracker.restriction_testcase import RestrictionTestCase
 
    def test_pass_non_drone(self):
        # Check that restriction is not applied
        # to holders which are not drones
        item = self.ch.type_(type_id=1, group_id=56)
        holder = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_calibration.py   Eos(Download)
from unittest.mock import Mock
 
from eos.const.eos import Location, State
from eos.const.eve import Attribute
from eos.fit.holder.item import ModuleHigh, Ship, Implant
        holder1.attributes = {Attribute.upgrade_cost: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.offline, item=item, _location=Location.character, spec_set=Implant(1))
        holder2.attributes = {Attribute.upgrade_cost: 30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/stat_tracker/slot/test_launched_drone.py   Eos(Download)
from eos.const.eos import Location, State
from eos.const.eve import Attribute
from eos.fit.holder.item import Character, Drone, Implant
from eos.tests.stat_tracker.stat_testcase import StatTestCase
 
    def test_use_other_class(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.online, item=item, _location=Location.space, spec_set=Implant(1))
        self.track_holder(holder)
        self.assertEqual(self.st.launched_drones.used, 0)

src/e/o/Eos-HEAD/tests/restriction_tracker/restrictions/test_launched_drone.py   Eos(Download)
 
from eos.const.eos import Location, Restriction, State
from eos.fit.holder.item import Drone, Implant
from eos.tests.restriction_tracker.restriction_testcase import RestrictionTestCase
 
    def test_pass_other_class(self):
        item = self.ch.type_(type_id=1)
        holder = Mock(state=State.online, item=item, _location=Location.space, spec_set=Implant(1))
        self.track_holder(holder)
        self.fit.stats.launched_drones.used = 1

src/e/o/Eos-HEAD/tests/restriction_tracker/restrictions/test_powergrid.py   Eos(Download)
from eos.const.eos import Location, Restriction, State
from eos.const.eve import Attribute
from eos.fit.holder.item import ModuleHigh, Implant
from eos.tests.restriction_tracker.restriction_testcase import RestrictionTestCase
 
    def test_fail_excess_single_other_class_location(self):
        # Make sure holders of all classes are affected
        item = self.ch.type_(type_id=1, attributes={Attribute.power: 0})
        holder = Mock(state=State.online, item=item, _location=Location.character, spec_set=Implant(1))
        holder.attributes = {Attribute.power: 50}

src/e/o/Eos-HEAD/tests/restriction_tracker/restrictions/test_drone_bandwidth.py   Eos(Download)
from eos.const.eos import Location, Restriction, State
from eos.const.eve import Attribute
from eos.fit.holder.item import Drone, Implant
from eos.tests.restriction_tracker.restriction_testcase import RestrictionTestCase
 
    def test_fail_excess_single_other_class_location(self):
        # Make sure holders of all classes are affected
        item = self.ch.type_(type_id=1, attributes={Attribute.drone_bandwidth_used: 0})
        holder = Mock(state=State.online, item=item, _location=Location.character, spec_set=Implant(1))
        holder.attributes = {Attribute.drone_bandwidth_used: 50}

  1 | 2  Next