书栈网 · BookStack 本次搜索耗时 0.057 秒,为您找到 249 个相关结果.
  • .toThrow(error)

    .toThrow(error) Also under the alias: .toThrowError(error) Use .toThrow to test that a function throws when it is called. For example, if we want to test that drinkFlavor('oct...
  • .rejects

    .rejects Use .rejects to unwrap the reason of a rejected promise so any other matcher can be chained. If the promise is fulfilled the assertion fails. For example, this code te...
  • .toHaveBeenCalled()

    .toHaveBeenCalled() Also under the alias: .toBeCalled() Use .toHaveBeenCalled to ensure that a mock function got called. For example, let's say you have a drinkAll(drink, fla...
  • Expect

    方法 参考 expect(value) expect.extend(matchers) this.isNot this.equals(a, b) this.expand this.utils expect.anything() expect.any(constructor) expect.arrayContaining(array) ex...
  • 24. How To Write Packages in Go

    702 2020-07-05 《How To Code in Go》
    How To Write Packages in Go Prerequisites Writing and Importing Packages Exported Code Conclusion How To Write Packages in Go Written by Gopher Guides A package is made up...
  • 关于监控

    指标类别 Controller Runtime 指标对照表 Controller 参数 Webhook 参数 Kubernetes 客户端指标对照表 Rest 客户端参数 Workqueue 参数 Prometheus 客户端指标对照表 Go runtime 参数 Running process 参数 Octopus 指标对照表 Limb ...
  • .toHaveBeenNthCalledWith(nthCall, arg1, arg2, ….)

    .toHaveBeenNthCalledWith(nthCall, arg1, arg2, ….) Also under the alias: .nthCalledWith(nthCall, arg1, arg2, …) If you have a mock function, you can use .toHaveBeenNthCalledWith...
  • MQTT 适配器

    MQTT 介绍 MQTT 杂谈 数据结构 操作 公约 AttributedTopic 模式 AttributedMessage JSONPath 用户案例 注册信息 支持模板 支持的平台 使用方式 权限 YAML 示例 MQTTDevice MQTTDeviceSpec MQTTDeviceStatus MQTTDeviceP...
  • 21. 如何在 Go 中编写包

    如何在 Go 中编写包 前提条件 编写和导入软件包 可导出代码 总结 如何在 Go 中编写包 一个包由同一目录下的 Go 文件组成的,并且在文件开头有相同的包声明。你可以从包中加入额外的功能,使你的程序更加复杂。有些包可以通过 Go 标准库获得,因此在安装 Go 时就已经安装了。其他的可以用 Go 的go get 命令来安装。你也可以通过在同一...
  • Expect

    方法 参考 expect(value) expect.extend(matchers) Async Matchers Custom Matchers API this.isNot this.equals(a, b) this.expand this.utils Custom snapshot matchers expect.anythin...