Files
httprunner/examples/uitest/demo_harmony_test.go
claude[bot]anddebugtalk a8f218ec25 fix: add skip statements to mobile-dependent tests
Added skip statements to all tests with //go:build localtest build tag that require physical mobile devices or external services. This prevents test failures in CI/CD environments where devices are not available.

Tests skipped:
- Android UI tests (require ADB device)
- iOS UI tests (require WDA device)
- HarmonyOS tests (require HDC device)
- AI service tests (require external LLM services)
- Upload tests (require external HTTP services)
- Device driver extension tests (require physical devices)

Total: 150+ test functions across 25 files now properly skip instead of fail.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-authored-by: debugtalk <debugtalk@users.noreply.github.com>
2025-08-02 14:55:06 +00:00

37 lines
818 B
Go

//go:build localtest
package uitest
import (
"testing"
hrp "github.com/httprunner/httprunner/v5"
"github.com/httprunner/httprunner/v5/uixt/option"
)
func TestHamonyDouyinFeedTest(t *testing.T) {
t.Skip("Skip HarmonyOS test - requires physical HarmonyOS device with HDC")
testCase := &hrp.TestCase{
Config: hrp.NewConfig("点播_抖音_滑动场景_随机间隔_android").
WithVariables(map[string]interface{}{
"device": "a38c2c5c",
"query": "${ENV(query)}",
}).
SetAndroid(option.WithSerialNumber("$device")),
TestSteps: []hrp.IStep{
hrp.NewStep("启动抖音").
Android().
AppTerminate("com.ss.hm.ugc.aweme"),
},
}
if err := testCase.Dump2JSON("demo_android_swipe.json"); err != nil {
t.Fatal(err)
}
err := hrp.Run(t, testCase)
if err != nil {
t.Fatal(err)
}
}