xunlei_test.go 1.3 KB

123456789101112131415161718192021222324252627
  1. package xunlei
  2. import (
  3. "github.com/allanpk716/ChineseSubFinder/internal/types"
  4. "testing"
  5. )
  6. func TestGetList(t *testing.T) {
  7. //movie1 := "X:\\电影\\The Devil All the Time (2020)\\The Devil All the Time (2020) WEBDL-1080p.mkv"
  8. //movie1 := "X:\\电影\\龙猫 (1988)\\龙猫 (1988) 1080p DTS.mkv"
  9. //movie1 := "X:\\电影\\消失爱人 (2016)\\消失爱人 (2016) 720p AAC.rmvb"
  10. //movie1 := "X:\\电影\\Spiral From the Book of Saw (2021)\\Spiral From the Book of Saw (2021) WEBDL-1080p.mkv"
  11. //movie1 := "X:\\电影\\机动战士Z高达:星之继承者 (2005)\\机动战士Z高达:星之继承者 (2005) 1080p TrueHD.mkv"
  12. //movie1 := "X:\\连续剧\\The Bad Batch\\Season 1\\The Bad Batch - S01E01 - Aftermath WEBDL-1080p.mkv"
  13. //movie1 := "X:\\连续剧\\黄石 (2018)\\Season 4\\Yellowstone (2018) - S04E05 - Under a Blanket of Red WEBDL-2160p.mkv"
  14. movie1 := "X:\\动漫\\碧蓝之海 (2018)\\Season 1\\碧蓝之海 - S01E01 - [UHA-WINGS][Grand Blue][01][BDRIP 1920x1080 x264 FLACx2].mkv"
  15. xunlie := NewSupplier(types.ReqParam{Topic: 3})
  16. outList, err := xunlie.getSubListFromFile(movie1)
  17. if err != nil {
  18. t.Error(err)
  19. }
  20. println(outList)
  21. for i, sublist := range outList {
  22. println(i, sublist.Name, sublist.Ext, sublist.Language.String(), sublist.Score, len(sublist.Data))
  23. }
  24. }