mirror of
https://github.com/2revoemag/PSF-BotServer.git
synced 2026-02-22 08:03:34 +00:00
tests and corrections
This commit is contained in:
parent
74863858f7
commit
72b7c35b3f
4 changed files with 54 additions and 2 deletions
|
|
@ -8,6 +8,7 @@ import net.psforever.objects.equipment.CItem.{DeployedItem, Unit}
|
|||
import net.psforever.objects.equipment._
|
||||
import net.psforever.objects.inventory.InventoryTile
|
||||
import net.psforever.objects.serverobject.terminals.Terminal
|
||||
import net.psforever.objects.serverobject.tube.SpawnTube
|
||||
import net.psforever.packet.game.PlanetSideGUID
|
||||
import net.psforever.packet.game.objectcreate._
|
||||
import net.psforever.types.{CharacterGender, PlanetSideEmpire, Vector3}
|
||||
|
|
@ -296,6 +297,26 @@ class ConverterTest extends Specification {
|
|||
}
|
||||
}
|
||||
|
||||
"Spawn Tube" should {
|
||||
"convert to packet" in {
|
||||
val obj = SpawnTube(GlobalDefinitions.ams_respawn_tube)
|
||||
|
||||
obj.Definition.Packet.DetailedConstructorData(obj) match {
|
||||
case Failure(err) =>
|
||||
err.isInstanceOf[NoSuchMethodException] mustEqual true
|
||||
case _ =>
|
||||
ko
|
||||
}
|
||||
|
||||
obj.Definition.Packet.ConstructorData(obj) match {
|
||||
case Success(pkt) =>
|
||||
pkt mustEqual CommonTerminalData(PlanetSideEmpire.NEUTRAL)
|
||||
case _ =>
|
||||
ko
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
"Vehicle" should {
|
||||
"convert to packet (1)" in {
|
||||
val hellfire_ammo = AmmoBoxDefinition(Ammo.hellfire_ammo.id)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue