This commit is contained in:
Akbar Yahya
2022-11-21 16:30:31 +08:00
commit e0d4d8040c
3326 changed files with 683000 additions and 0 deletions

View File

@@ -0,0 +1,45 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineAddClient",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineAddClient"
self.Category = "联机"
self.Description="联机增加一台客机进入本机"
self.GetUserId = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="增加一个远程玩家,并传送到主机身边",
Action = UAutoCoroutine(function()
yield_return(self:FinishAllNoob())
self.base:SetUpUserId()
end)
}
self.AddClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="增加一个远程玩家,并传送到主机身边",
Action = UAutoCoroutine(function()
yield_return(self.base:SetUpUserID(self.base.driver.HostUserId))
yield_return(self:FinishAllNoob())
local cmd ="enter " .. self.base.driver.HostUserId
yield_return(self.base:RunGM(cmd))
yield_return(self.base:RunGM("wudi on"))
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
end)
}
return self

View File

@@ -0,0 +1,93 @@
local baseClass = require('UAuto/Base/UAutoLuaTestBase')
local UAutoLuaTestCase = class("OnlineBase",baseClass)
UAutoLuaTestCase.TestFixture = "OnlineBase"
UAutoLuaTestCase.base = TestCaseNetworkBaseClass()
--setmetatable(UAutoLuaTestCase,{ __index = UAutoLuaTestCase.base })
local self = UAutoLuaTestCase
self.hostStartPos = "1955.741 196.5956 -1298.704"
self.clientPointStr = "1962.768 197.9143 -1306.191"
self.hostStartPosVec = CS.UnityEngine.Vector3(1955.741,196.5956,-1298.704)
self.clientPointVec = CS.UnityEngine.Vector3(1962.768,197.9143,-1306.191)
function self:GetRemoteAvatar()
local entityManager = singletonManager:GetSingletonInstance("MoleMole.EntityManager")
local Avatars = entityManager:GetAllAvatars()
for k,v in pairs(Avatars) do
if v.isAuthority==false and v:IsActive() then
return Avatars[k]
end
end
return nil
end
function self:GetLocalAvatar()
local entityManager = singletonManager:GetSingletonInstance("MoleMole.EntityManager")
local Avatars = entityManager:GetAllAvatars()
for k,v in pairs(Avatars) do
if v.isAuthority==true and v:IsActive() then
return Avatars[k]
end
end
return nil
end
function self:CheckPosition()
return true
end
function self:CheckEffect(localCount, RemoteCount)
localCount = localCount or 0
RemoteCount = RemoteCount or 0
self.remoteAvater = self:GetRemoteAvatar()
self.EffectManager = singletonManager:GetSingletonInstance("MoleMole.EffectManager")
self.MonoEffectList = self.EffectManager:GetEffectsByOwner(self.remoteAvater.runtimeID)
self.LocalMonoEffectList = self.EffectManager:GetEffectsByOwner(self.base.avatar.runtimeID)
print("local:" .. tostring(self.LocalMonoEffectList.Count))
assert(self.LocalMonoEffectList.Count==localCount,"local avatar特效数量不正确")
if(self.MonoEffectList.Count>=RemoteCount) then
return true
else
return false
end
end
function self:CheckAnimation()
return true
end
function self:CheckState()
return true
end
function self:CheckRemoteAvatar(name)
self.remote = self:GetRemoteAvatar()
if self.remote~=nil then
if string.find(self.remote.gameObject.name,name) then
print(name.." Checked.")
return true
end
end
return false
end
function self:CheckRemoteAvatarPosition(endPosition)
self.endPoint = endPosition
self.remote = self:GetRemoteAvatar()
assert(self.remote~=nil,"远程玩家未找到")
local timeout=500
local timePassed=0
while CS.UnityEngine.Vector3.Distance(self.remote.transform.position,self.endPoint) > 1 do
timePassed = timePassed + CS.UnityEngine.Time.deltaTime
assert(timeout>0,"远程玩家位置未在500ms内同步到主机,实际耗时:"..timePassed)
yield_return(CS.UnityEngine.WaitForSeconds(0.01))
timeout = timeout-10
end
end
return self

View File

@@ -0,0 +1,116 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineChangeAvatar",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineChangeAvatar"
self.Category = "联机"
self.Description="联机切换角色"
self.startPointStr = "2821.3571 211.1067 -1720.1761"
self.startPointStr2 = "2823.3571 215.1067 -1720.1761"
self.ClientCheckHostAvatar = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
IsSync = IsSync.False,
Description="客机验证主机切换角色",
Action = UAutoCoroutine(function()
local timeout = 120
local ambor=false
local ayaka=false
local qin=false
local lisa=false
while ambor==false or ayaka==false or qin==false or lisa==false do
if self:CheckRemoteAvatar("Ambor") then
ambor=true
end
if self:CheckRemoteAvatar("Ayaka") then
ayaka=true
end
if self:CheckRemoteAvatar("Qin") then
qin=true
end
if self:CheckRemoteAvatar("Lisa") then
lisa=true
end
yield_return(CS.UnityEngine.WaitForSeconds(0.1))
timeout = timeout-0.1
local log = " 安柏: "..tostring(ambor).." 绫华: "..tostring(ayaka).." 琴: "..tostring(qin).." 丽莎: "..tostring(lisa)
assert(timeout>0,"客机验证切换角色失败 "..log)
end
end)
}
self.HostChangeAvatar = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机切换角色",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Anbo"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Qin"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Lisa"))
end)
}
self.ClientChangeAvatar = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机切换角色",
IsSync = IsSync.False,
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Anbo"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Qin"))
yield_return(CS.UnityEngine.WaitForSeconds(1))
yield_return(self:ChangeAvatar("Lisa"))
end)
}
self.HostCheckClientAvatar = {
Order = 4,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机切换角色",
Action = UAutoCoroutine(function()
local timeout = 120
local ambor=false
local ayaka=false
local qin=false
local lisa=false
while ambor==false or ayaka==false or qin==false or lisa==false do
if self:CheckRemoteAvatar("Ambor") then
ambor=true
end
if self:CheckRemoteAvatar("Ayaka") then
ayaka=true
end
if self:CheckRemoteAvatar("Qin") then
qin=true
end
if self:CheckRemoteAvatar("Lisa") then
lisa=true
end
yield_return(CS.UnityEngine.WaitForSeconds(0.1))
timeout = timeout-0.1
local log = " 安柏: "..tostring(ambor).." 绫华: "..tostring(ayaka).." 琴: "..tostring(qin).." 丽莎: "..tostring(lisa)
assert(timeout>0,"主机验证切换角色失败 "..log)
end
end)
}
return self

View File

@@ -0,0 +1,109 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineElementElectric",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineElementElectric"
self.Category = "联机"
self.Description = "联机-怪物元素-电"
self.MonsterId = 20010601
self.MonsterKeyWord = "Slime_Electric_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.localHostStartPos = self.hostStartPos
self.localClientPointStr = self.clientPointStr
self.localHostStartPosVec = self.hostStartPosVec
self.localClientPointVec = self.clientPointVec
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.localHostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.localHostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.localClientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.localClientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
--self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("MONSTER "..self.MonsterId.." 1 1"))
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:StartSyncRecord(0,true))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostFireAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机火攻怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckFireAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证火攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,157 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineElementFire",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineElementFire"
self.Category = "联机"
self.Description = "联机-怪物元素-火"
self.MonsterId = 20011301
self.MonsterKeyWord = "Slime_Fire_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Razor"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
--self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("MONSTER "..self.MonsterId.." 1 1"))
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:StartSyncRecord(0,true))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostElectricAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机电攻怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckElectricAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证电攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostIceAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机冰攻怪",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckIceAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证冰攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostWaterAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机水攻怪",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckWaterAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证水攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,106 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineElementGrass",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineElementGrass"
self.Category = "联机"
self.Description = "联机-怪物元素-草"
self.MonsterId = 20010101
self.MonsterKeyWord = "Slime_Grass_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
--self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("MONSTER "..self.MonsterId.." 1 1"))
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:StartSyncRecord(0,true))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostFireAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机火攻怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(4))
-- 等待草史莱姆头上的草烧掉
yield_return(CS.UnityEngine.WaitForSeconds(10))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckFireAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证火攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,111 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineElementIce",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineElementIce"
self.Category = "联机"
self.Description = "联机-怪物元素-冰"
self.MonsterId = 20010901
self.MonsterKeyWord = "Slime_Ice_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.localHostStartPos = self.hostStartPos
self.localClientPointStr = self.clientPointStr
self.localHostStartPosVec = self.hostStartPosVec
self.localClientPointVec = self.clientPointVec
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.localHostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.localHostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.localClientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.localClientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
--self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("MONSTER "..self.MonsterId.." 1 1"))
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:StartSyncRecord(0,true))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostFireAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机火攻怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(4))
-- 等待冰史莱姆头上的冰烧掉
yield_return(CS.UnityEngine.WaitForSeconds(10))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckFireAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证火攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,158 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineElementWater",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineElementWater"
self.Category = "联机"
self.Description = "联机-怪物元素-水"
self.MonsterId = 20011001
self.MonsterKeyWord = "Slime_Water_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
--self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("MONSTER "..self.MonsterId.." 1 1"))
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:StartSyncRecord(0,true))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostFireAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机火攻怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckFireAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证火攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostIceAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机冰攻怪",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckIceAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证冰攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostElectricAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机电攻怪",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Razor"))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckElectricAttack = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证电攻怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,282 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("AbyssFire01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "AbyssFire01"
self.Category = "联机"
self.Description = "联机-深渊巫师-火"
self.MonsterId = 22010101
self.MonsterKeyWord = "Abyss_Fire_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
self.base:MonsterGod()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(CS.UnityEngine.WaitForSeconds(20))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
self.base:MonsterGod(false)
end)
}
return self

View File

@@ -0,0 +1,279 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("AbyssIce01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "AbyssIce01"
self.Category = "联机"
self.Description = "联机-深渊巫师-冰"
self.MonsterId = 22010201
self.MonsterKeyWord = "Abyss_Ice_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(CS.UnityEngine.WaitForSeconds(20))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,279 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("AbyssWater01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "AbyssWater01"
self.Category = "联机"
self.Description = "联机-深渊巫师-水"
self.MonsterId = 22010301
self.MonsterKeyWord = "Abyss_Water_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(CS.UnityEngine.WaitForSeconds(20))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,328 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("BruteNoneShield",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "BruteNoneShield"
self.Category = "联机"
self.Description = "联机-暴徒-无-巨盾"
self.MonsterId = 21020101
self.MonsterKeyWord = "Brute_None_Shield"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill6 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能6",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,6)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill6 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能6一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,278 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("DefenderNone01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "DefenderNone01"
self.Category = "联机"
self.Description = "联机-空手遗迹守卫"
self.MonsterId = 23040101
self.MonsterKeyWord = "Defender_None_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,252 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("ElementalWind01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "ElementalWind01"
self.Category = "联机"
self.Description = "联机-元素球-风"
self.MonsterId = 20020101
self.MonsterKeyWord = "Elemental_Wind_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,186 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("HiliNone01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "HiliNone01"
self.Category = "联机"
self.Description = "联机-空手丘丘人"
self.MonsterId = 21010101
self.MonsterKeyWord = "Hili_None_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
yield_return(self.base:RunGM("Level 1"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:RunGM("Level 1"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.base:MonsterAI(true)
yield_return(CS.UnityEngine.WaitForSeconds(1))
self.base:MonsterAI(false)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
self.remoteAvater = self:GetRemoteAvatar()
self.localAvatar = self:GetLocalAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:MonsterMove(self.foundEntity,self.localAvatar.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,333 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("HiliNone01Club",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "HiliNone01Club"
self.Category = "联机"
self.Description = "联机-空手丘丘人-近战"
self.MonsterId = 21010201
self.MonsterKeyWord = "Hili_None_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.base:MonsterAI(true)
yield_return(CS.UnityEngine.WaitForSeconds(1))
self.base:MonsterAI(false)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
self.remoteAvater = self:GetRemoteAvatar()
self.localAvatar = self:GetLocalAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:MonsterMove(self.foundEntity,self.localAvatar.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能7",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,7)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能7一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能8",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,8)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能8一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,333 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("HiliNone01Range",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "HiliNone01Range"
self.Category = "联机"
self.Description = "联机-空手丘丘人-远程"
self.MonsterId = 21010401
self.MonsterKeyWord = "Hili_None_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.base:MonsterAI(true)
yield_return(CS.UnityEngine.WaitForSeconds(1))
self.base:MonsterAI(false)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
self.remoteAvater = self:GetRemoteAvatar()
self.localAvatar = self:GetLocalAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:MonsterMove(self.foundEntity,self.localAvatar.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能7",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,7)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能7一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能8",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,8)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能8一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,333 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("HiliNone01Shield",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "HiliNone01Shield"
self.Category = "联机"
self.Description = "联机-空手丘丘人-小盾"
self.MonsterId = 21010301
self.MonsterKeyWord = "Hili_None_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.base:MonsterAI(true)
yield_return(CS.UnityEngine.WaitForSeconds(1))
self.base:MonsterAI(false)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
self.remoteAvater = self:GetRemoteAvatar()
self.localAvatar = self:GetLocalAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:MonsterMove(self.foundEntity,self.localAvatar.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能7",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,7)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能7一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能8",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,8)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill8 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能8一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("ShamanGrass01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "ShamanGrass01"
self.Category = "联机"
self.Description = "联机-丘丘萨满-草"
self.MonsterId = 21030201
self.MonsterKeyWord = "Shaman_Grass_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("ShamanWater01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "ShamanWater01"
self.Category = "联机"
self.Description = "联机-丘丘萨满-水"
self.MonsterId = 21030101
self.MonsterKeyWord = "Shaman_Water_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("ShamanWind01",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "ShamanWind01"
self.Category = "联机"
self.Description = "联机-丘丘萨满-风"
self.MonsterId = 21030301
self.MonsterKeyWord = "Shaman_Wind_01"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeElectric02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeElectric02"
self.Category = "联机"
self.Description = "联机-电史莱姆-中"
self.MonsterId = 20010501
self.MonsterKeyWord = "Slime_Electric_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeElectric03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeElectric03"
self.Category = "联机"
self.Description = "联机-电史莱姆-大"
self.MonsterId = 20010601
self.MonsterKeyWord = "Slime_Electric_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeElectric03Positive",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeElectric03Positive"
self.Category = "联机"
self.Description = "联机-电史莱姆-大-正"
self.MonsterId = 20010701
self.MonsterKeyWord = "Slime_Electric_03_Positive"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,203 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeFire02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeFire02"
self.Category = "联机"
self.Description = "联机-火史莱姆-中"
self.MonsterId = 20011201
self.MonsterKeyWord = "Slime_Fire_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,253 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeFire03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeFire03"
self.Category = "联机"
self.Description = "联机-火史莱姆-大"
self.MonsterId = 20011301
self.MonsterKeyWord = "Slime_Fire_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,253 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeGrass02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeGrass02"
self.Category = "联机"
self.Description = "联机-草史莱姆-中"
self.MonsterId = 20010101
self.MonsterKeyWord = "Slime_Grass_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,353 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeGrass03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeGrass03"
self.Category = "联机"
self.Description = "联机-草史莱姆-大"
self.MonsterId = 20010201
self.MonsterKeyWord = "Slime_Grass_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能5",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,5)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill5 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能5一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill6 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能6",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,6)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill6 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能6一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能7",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,7)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill7 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能7一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,178 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeIce02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeIce02"
self.Category = "联机"
self.Description = "联机-冰史莱姆-中"
self.MonsterId = 20010801
self.MonsterKeyWord = "Slime_Ice_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,278 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeIce03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeIce03"
self.Category = "联机"
self.Description = "联机-冰史莱姆-大"
self.MonsterId = 20010901
self.MonsterKeyWord = "Slime_Ice_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,203 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeRock02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeRock02"
self.Category = "联机"
self.Description = "联机-岩史莱姆-中"
self.MonsterId = 20011401
self.MonsterKeyWord = "Slime_Rock_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeRock03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeRock03"
self.Category = "联机"
self.Description = "联机-岩史莱姆-大"
self.MonsterId = 20011501
self.MonsterKeyWord = "Slime_Rock_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,178 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeWater02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeWater02"
self.Category = "联机"
self.Description = "联机-水史莱姆-中"
self.MonsterId = 20011001
self.MonsterKeyWord = "Slime_Water_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeWater03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeWater03"
self.Category = "联机"
self.Description = "联机-水史莱姆-大"
self.MonsterId = 20011101
self.MonsterKeyWord = "Slime_Water_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能4",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,4)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill4 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能4一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能3",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,3)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill3 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能3一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,203 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeWind02",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeWind02"
self.Category = "联机"
self.Description = "联机-风史莱姆-中"
self.MonsterId = 20010301
self.MonsterKeyWord = "Slime_Wind_02"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 1
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,228 @@
-- baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
-- 所有testcase继承baseClass
local UAutoLuaTestCase = class("SlimeWind03",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "SlimeWind03"
self.Category = "联机"
self.Description = "联机-风史莱姆-大"
self.MonsterId = 20010401
self.MonsterKeyWord = "Slime_Wind_03"
-- c#中写了120这边先写着不改
self.FindTimeOut = 120
-- 胖怪先填3瘦怪填1
self.FatRange = 3
self.OrderIndex = 1
self.SetUpHost = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "初始化主机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("KILL MONSTER ALL"))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.SetUpClient = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "初始化客机角色位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("WUDI ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.base:MonsterAI(false)
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostCreateMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机招怪",
Action = UAutoCoroutine(function()
self.base:CreateMonster(self.MonsterId)
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientFindMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪创建",
Action = UAutoCoroutine(function()
yield_return(self:WaitFoundEntity(self.MonsterKeyWord))
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪移动至客机角色",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("AUTHORITY REFRESH"))
self.remoteAvater = self:GetRemoteAvatar()
yield_return(self.base:MonsterMove(self.foundEntity,self.remoteAvater.transform.position))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckMonsterMove = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证怪移动",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能0",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,0)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill0 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能0一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能1",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,1)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill1 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能1一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机怪放技能2",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
self.base:MonsterDoSkill(self.foundEntity,2)
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckSkill2 = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证技能2一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机攻击怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("WUDI MONSTER ON"))
yield_return(self.base:MoveToEntity(self.foundEntity,self.FindTimeOut,self.FatRange))
yield_return(self.base:Skill(0))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckAttackMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证攻击怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.HostKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description = "主机杀死怪",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord(self.foundEntity.runtimeID,true))
yield_return(self.base:StartSyncRecord())
yield_return(self.base:RunGM("kill monster "..tostring(self.MonsterId)))
yield_return(self.base:StopSyncRecord())
end)
}
self.OrderIndex = self.OrderIndex + 1;
self.ClientCheckKillMonster = {
Order = self.OrderIndex,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description = "客机验证杀死怪一致性",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,98 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineMove",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineMove"
self.Category = "联机"
self.Description="联机角色移动"
self.endPoint = CS.UnityEngine.Vector3(2786.4963, 197.7144,-1734.688)
self.startPointStr = "2821.3571 211.1067 -1720.1761"
self.startPointStr2 = "2819.522 206.2345 -1727.416"
self.startPoint2 = CS.UnityEngine.Vector3(2819.522,206.2345,-1727.416)
self.startPoint = CS.UnityEngine.Vector3(2821.3571,211.1067,-1720.1761)
self.endPoint2 = CS.UnityEngine.Vector3(2792.585,197.788,-1736.934)
self.SetUpHost = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:TelePort(self.startPoint))
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
end)
}
self.SetUpClient = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:TelePort(self.startPoint2))
yield_return(self.base:Jump())
yield_return(CS.UnityEngine.WaitForSeconds(3))
end)
}
self.ClientMove = {
Order = 4,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机移动到某点",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.endPoint))
yield_return(self.base:Jump())
end)
}
self.CheckClientPosition = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机检查客机是否移动到位",
Action = UAutoCoroutine(function()
yield_return(self:CheckRemoteAvatarPosition(self.endPoint))
print(self.remote.transform.position)
yield_return(self.base:Jump())
end)
}
self.HostMove = {
Order = 6,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机移动到某点",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.endPoint2))
yield_return(self.base:Jump())
end)
}
self.CheckHostPosition = {
Order = 7,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机检查主机是否移动到位",
Action = UAutoCoroutine(function()
yield_return(self:CheckRemoteAvatarPosition(self.endPoint2))
print(self.remote.transform.position)
yield_return(self.base:Jump())
end)
}
return self

View File

@@ -0,0 +1,153 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineAmborSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineAmborSkill"
self.Category = "联机"
self.Description="联机安柏技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Anbo"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 3
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.3))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的箭,动作",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1娃娃",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1,false))
yield_return(CS.UnityEngine.WaitForSeconds(2))
yield_return(self.base:SkillUp(1))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机娃娃所产生的特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill2 = {
Order = 4,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能2瞄准射击",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(0,false))
yield_return(CS.UnityEngine.WaitForSeconds(2))
yield_return(self.base:MoveByAngle(180))
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:MoveByAngle(180,true))
self.remote = self:GetRemoteAvatar()
yield_return(self.base:RotateCamera(self.remote.transform.position))
yield_return(self.base:SkillUp(0,true))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill2 = {
Order = 4.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机瞄准射击所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,280 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineAyakaSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineAyakaSkill"
self.Category = "联机"
self.Description="联机绫华技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.hostStartPos,true,true))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:RunGM("kill monster all"))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("goto "..self.clientPointStr,true,true))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
self.remote = self:GetRemoteAvatar()
yield_return(self.base:RotateCamera(self.remote.transform.position))
yield_return(self.base:RunGM("kill monster all"))
yield_return(CS.UnityEngine.WaitForSeconds(10))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 6
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.3))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1冰刺",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机冰刺所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill2 = {
Order = 4,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能2水激流",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(2,false))
yield_return(self.base:MoveByAngle(180))
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:Skill(2,true))
yield_return(self.base:MoveByAngle(180,true))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill2 = {
Order = 4.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机水激流所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
--client do host check
self.SetUpClient2 = {
Order = 10.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("Ayaka"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.SetUpHost2 = {
Order = 10.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill0 = {
Order = 11,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放普攻",
Action = UAutoCoroutine(function()
local attackCount = 6
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.3))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
end)
}
self.HostCheckSkill0 = {
Order = 12,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill1 = {
Order = 13,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能1冰刺",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(1))
end)
}
self.HostCheckSkill1 = {
Order = 13.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机冰刺所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill2 = {
Order = 14,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能2水激流",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(2,false))
yield_return(self.base:MoveByAngle(180))
yield_return(CS.UnityEngine.WaitForSeconds(3))
yield_return(self.base:Skill(2,true))
yield_return(self.base:MoveByAngle(180,true))
end)
}
self.HostCheckSkill2 = {
Order = 14.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机水激流所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill4 = {
Order = 15,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(4))
yield_return(CS.UnityEngine.WaitForSeconds(10))
end)
}
self.HostCheckSkill4 = {
Order = 15.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,111 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineBarbaraSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineBarbaraSkill"
self.Category = "联机"
self.Description="联机芭芭拉技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Barbara"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 5
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.2))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的特效,动作",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1水环",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1))
yield_return(CS.UnityEngine.WaitForSeconds(10))--等待水环完成
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机水环所产生的特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,115 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineGirlSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineGirlSkill"
self.Category = "联机"
self.Description="联机女主技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("PlayerGirl"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:RunGM("SKILL DEPOT 704"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self:ChangeAvatar("PlayerGirl"))
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self.base:RunGM("SKILL DEPOT 704"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 5
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.35))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的特效,动作",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1蓄力风球",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1,false))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:SkillUp(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机蓄力风球所产生的特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,249 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineKaeyaSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineKaeyaSkill"
self.Category = "联机"
self.Description="联机凯亚技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Kaeya"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Kaeya"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 5
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.15))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1冰突刺",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机冰突刺所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
-- self.HostDoSkill2 = {
-- Order = 4,
-- Type = CaseType.MonoTest,
-- RunMode = RunMode.Host,
-- Description="主机放技能2雷电蓄力",
-- Action = UAutoCoroutine(function()
-- yield_return(self.base:StartSyncRecord())
-- yield_return(self.base:Skill(1,false))
-- yield_return(CS.UnityEngine.WaitForSeconds(5))
-- yield_return(self.base:Skill(1,true))
-- yield_return(self.base:StopSyncRecord())
-- end)
-- }
-- self.ClientCheckSkill2 = {
-- Order = 4.5,
-- Type = CaseType.MonoTest,
-- RunMode = RunMode.Client,
-- Description="客机验证主机雷电蓄力所产生的位移、特效、动作、状态",
-- Action = UAutoCoroutine(function()
-- yield_return(self.base:StopSyncRecord())
-- self.base:CheckRemote()
-- yield_return(self.base:StartSyncRecord())
-- end)
-- }
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
--client do host check
self.SetUpClient2 = {
Order = 10.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.SetUpHost2 = {
Order = 10.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill0 = {
Order = 11,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 5
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.15))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.HostCheckSkill0 = {
Order = 12,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill1 = {
Order = 13,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能1冰突刺",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.HostCheckSkill1 = {
Order = 13.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机冰刺所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill4 = {
Order = 15,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.HostCheckSkill4 = {
Order = 15.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
return self

View File

@@ -0,0 +1,265 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineLisaSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineLisaSkill"
self.Category = "联机"
self.Description="联机丽莎技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Lisa"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Lisa"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 3
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.15))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1闪电球",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1))
yield_return(CS.UnityEngine.WaitForSeconds(10))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机闪电球所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill2 = {
Order = 4,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能2雷电蓄力",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1,false))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:Skill(1,true))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill2 = {
Order = 4.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机雷电蓄力所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
--client do host check
self.SetUpClient2 = {
Order = 10.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.SetUpHost2 = {
Order = 10.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill0 = {
Order = 11,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放普攻",
Action = UAutoCoroutine(function()
local attackCount = 3
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.15))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
end)
}
self.HostCheckSkill0 = {
Order = 12,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机普攻所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill1 = {
Order = 13,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能1闪电球",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(1))
yield_return(CS.UnityEngine.WaitForSeconds(10))
end)
}
self.HostCheckSkill1 = {
Order = 13.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机冰刺所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill2 = {
Order = 14,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能2蓄力电击",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(1,false))
yield_return(CS.UnityEngine.WaitForSeconds(5))
yield_return(self.base:Skill(1,true))
end)
}
self.HostCheckSkill2 = {
Order = 14.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机蓄力点击所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
yield_return(self.base:StartSyncRecord())
end)
}
self.ClientDoSkill4 = {
Order = 15,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:Skill(4))
end)
}
self.HostCheckSkill4 = {
Order = 15.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机验证客机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
yield_return(self.base:StopSyncRecord())
self.base:CheckRemote()
end)
}
return self

View File

@@ -0,0 +1,115 @@
--baseClass提供基础接口
local baseClass = require('UAuto/TestCases/Online/OnlineBase')
--所有testcase继承baseClass
local UAutoLuaTestCase = class("OnlineQinSkill",baseClass)
local self = UAutoLuaTestCase
self.TestFixture = "OnlineQinSkill"
self.Category = "联机"
self.Description="联机琴技能"
self.SetUpHost = {
Order = 0.1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="初始化主机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Qin"))
yield_return(self.base:MoveToPosition(self.hostStartPosVec))
end)
}
self.SetUpClient = {
Order = 0.2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="初始化客机位置",
Action = UAutoCoroutine(function()
yield_return(self.base:RunGM("ENERGY INFINITE ON"))
yield_return(self:ChangeAvatar("Qin"))
yield_return(self.base:MoveToPosition(self.clientPointVec))
end)
}
self.HostDoSkill0 = {
Order = 1,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放普攻",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
local attackCount = 5
while attackCount > 0 do
yield_return(CS.UnityEngine.WaitForSeconds(0.2))
yield_return(self.base:Skill(0))
attackCount = attackCount - 1
end
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill0 = {
Order = 2,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机普攻所产生的特效,动作",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill1 = {
Order = 3,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能1风压剑",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(1,false))
self.remote = self:GetRemoteAvatar()
yield_return(self.base:RotateCamera(self.remote.transform.position))
yield_return(CS.UnityEngine.WaitForSeconds(4))
yield_return(self.base:SkillUp(1))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill1 = {
Order = 3.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机风压剑所产生的特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
self.HostDoSkill4 = {
Order = 5,
Type = CaseType.MonoTest,
RunMode = RunMode.Host,
Description="主机放技能3充能技",
Action = UAutoCoroutine(function()
yield_return(self.base:StartSyncRecord())
yield_return(self.base:Skill(4))
yield_return(self.base:StopSyncRecord())
end)
}
self.ClientCheckSkill4 = {
Order = 5.5,
Type = CaseType.MonoTest,
RunMode = RunMode.Client,
Description="客机验证主机充能技所产生的位移、特效、动作、状态",
Action = UAutoCoroutine(function()
self.base:CheckRemote()
end)
}
return self