feat: publish v1.0.0-rc.36-custom.1
This commit is contained in:
commit
3a7e8f3b54
2381 files changed
+551494
No files matched your search
@@ -0,0 +1,18 @@
|
||||
package relay
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestGetTaskPlatformPriority(t *testing.T) {
|
||||
c, _ := gin.CreateTestContext(nil)
|
||||
c.Set("platform", "fallback")
|
||||
assert.Equal(t, "fallback", string(GetTaskPlatform(c)))
|
||||
c.Set("channel_type", 59)
|
||||
assert.Equal(t, "59", string(GetTaskPlatform(c)))
|
||||
c.Set("task_plugin_key", "document-parser")
|
||||
assert.Equal(t, "document-parser", string(GetTaskPlatform(c)))
|
||||
}
|
||||
Reference in new issue
Block a user