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

All Samples(133)  |  Call(133)  |  Derive(0)  |  Import(0)

src/e/o/Eos-HEAD/tests/stat_tracker/damage/test_nominal_volley.py   Eos(Download)
    def test_single(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder)
        holder_volley = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)
    def test_multiple(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder1 = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        holder2 = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
    def test_not_damage_dealer(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item)
        self.track_holder(holder)
        holder_volley = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)
    def test_arguments_custom(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder)
        holder_volley = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)

src/e/o/Eos-HEAD/tests/stat_tracker/damage/test_nominal_dps.py   Eos(Download)
    def test_single(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder)
        holder_dps = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)
    def test_multiple(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder1 = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        holder2 = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
    def test_not_damage_dealer(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item)
        self.track_holder(holder)
        holder_dps = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)
    def test_arguments_custom(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.active, item=item, spec=ModuleHigh(1))
        self.track_holder(holder)
        holder_dps = Mock(em=1.2, thermal=2.3, kinetic=3.4, explosive=4.5, total=5.6)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_drone_bandwidth.py   Eos(Download)
    def test_use_single_no_rounding(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.drone_bandwidth_used: 0})
        holder = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder.attributes = {Attribute.drone_bandwidth_used: 55.5555555555}
        self.track_holder(holder)
    def test_use_multiple(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.drone_bandwidth_used: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder1.attributes = {Attribute.drone_bandwidth_used: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder2.attributes = {Attribute.drone_bandwidth_used: 30}
        self.track_holder(holder2)
    def test_use_negative(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.drone_bandwidth_used: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder1.attributes = {Attribute.drone_bandwidth_used: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder2.attributes = {Attribute.drone_bandwidth_used: -30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_calibration.py   Eos(Download)
    def test_use_single_no_rounding(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.upgrade_cost: 0})
        holder = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder.attributes = {Attribute.upgrade_cost: 55.5555555555}
        self.track_holder(holder)
    def test_use_multiple(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.upgrade_cost: 0})
        holder1 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.upgrade_cost: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2.attributes = {Attribute.upgrade_cost: 30}
        self.track_holder(holder2)
    def test_use_negative(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.upgrade_cost: 0})
        holder1 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.upgrade_cost: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2.attributes = {Attribute.upgrade_cost: -30}
        self.track_holder(holder2)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_powergrid.py   Eos(Download)
    def test_use_single_rounding_up(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.power: 0})
        holder = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder.attributes = {Attribute.power: 55.5555555555}
        self.track_holder(holder)
    def test_use_single_rounding_down(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.power: 0})
        holder = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder.attributes = {Attribute.power: 44.4444444444}
        self.track_holder(holder)
    def test_use_multiple(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.power: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.power: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2.attributes = {Attribute.power: 30}
        self.track_holder(holder2)
    def test_use_negative(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.power: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.power: 50}
        self.track_holder(holder1)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_cpu.py   Eos(Download)
    def test_use_single_rounding_up(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.cpu: 0})
        holder = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder.attributes = {Attribute.cpu: 55.5555555555}
        self.track_holder(holder)
    def test_use_single_rounding_down(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.cpu: 0})
        holder = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder.attributes = {Attribute.cpu: 44.4444444444}
        self.track_holder(holder)
    def test_use_multiple(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.cpu: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.cpu: 50}
        self.track_holder(holder1)
        holder2 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2.attributes = {Attribute.cpu: 30}
        self.track_holder(holder2)
    def test_use_negative(self):
        item = self.ch.type_(type_id=1, attributes={Attribute.cpu: 0})
        holder1 = Mock(state=State.online, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder1.attributes = {Attribute.cpu: 50}
        self.track_holder(holder1)

src/e/o/Eos-HEAD/tests/stat_tracker/slot/test_launched_drone.py   Eos(Download)
    def test_use_single(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        self.track_holder(holder)
        self.assertEqual(self.st.launched_drones.used, 1)
    def test_use_multiple(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder1 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        holder2 = Mock(state=State.online, item=item, _location=Location.space, spec_set=Drone(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
    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)
    def test_use_state(self):
        item = self.ch.type_(type_id=1, attributes={})
        holder = Mock(state=State.offline, item=item, _location=Location.space, spec_set=Drone(1))
        self.track_holder(holder)
        self.assertEqual(self.st.launched_drones.used, 0)

src/e/o/Eos-HEAD/tests/stat_tracker/slot/test_turret.py   Eos(Download)
    def test_use_single(self):
        item = self.ch.type_(type_id=1, attributes={})
        item.slots = {Slot.turret}
        holder = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder)
    def test_use_other_slot(self):
        item = self.ch.type_(type_id=1, attributes={})
        item.slots = {Slot.launcher}
        holder = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder)
        holder1 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
        self.assertEqual(self.st.turret_slots.used, 2)
        item2.slots = {Slot.launcher}
        holder2 = Mock(state=State.offline, item=item2, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
        self.assertEqual(self.st.turret_slots.used, 1)

src/e/o/Eos-HEAD/tests/stat_tracker/slot/test_launcher.py   Eos(Download)
    def test_use_single(self):
        item = self.ch.type_(type_id=1, attributes={})
        item.slots = {Slot.launcher}
        holder = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder)
    def test_use_other_slot(self):
        item = self.ch.type_(type_id=1, attributes={})
        item.slots = {Slot.turret}
        holder = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder)
        holder1 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        holder2 = Mock(state=State.offline, item=item, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
        self.assertEqual(self.st.launcher_slots.used, 2)
        item2.slots = {Slot.turret}
        holder2 = Mock(state=State.offline, item=item2, _location=Location.ship, spec_set=ModuleHigh(1))
        self.track_holder(holder1)
        self.track_holder(holder2)
        self.assertEqual(self.st.launcher_slots.used, 1)

src/e/o/Eos-HEAD/tests/stat_tracker/resource/test_dronebay_volume.py   Eos(Download)
        holder.attributes = {Attribute.volume: 55.5555555555}
        self.fit.drones.add(holder)
        self.track_holder(holder)
        self.assertEqual(self.st.dronebay.used, 55.5555555555)
        self.untrack_holder(holder)
        holder1.attributes = {Attribute.volume: 50}
        self.fit.drones.add(holder1)
        self.track_holder(holder1)
        holder2 = Mock(state=State.offline, item=item, _location=Location.space, spec_set=Drone(1))
        holder2.attributes = {Attribute.volume: 30}
        self.fit.drones.add(holder2)
        self.track_holder(holder2)
        holder1.attributes = {Attribute.volume: 50}
        self.fit.drones.add(holder1)
        self.track_holder(holder1)
        holder2 = Mock(state=State.offline, item=item, _location=Location.space, spec_set=Drone(1))
        holder2.attributes = {Attribute.volume: -30}
        self.fit.drones.add(holder2)
        self.track_holder(holder2)