⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 winnotify.test

📁 linux系统下的音频通信
💻 TEST
字号:
# This file tests the tclWinNotify.c file.## This file contains a collection of tests for one or more of the Tcl# built-in commands.  Sourcing this file into Tcl runs the tests and# generates output for errors.  No output means no errors were found.## Copyright (c) 1997 by Sun Microsystems, Inc.## See the file "license.terms" for information on usage and redistribution# of this file, and for a DISCLAIMER OF ALL WARRANTIES.## SCCS: @(#) winNotify.test 1.2 97/04/14 17:24:56if {[string compare test [info procs test]] == 1} then {source defs}if {$tcl_platform(platform) != "windows"} {    return}# There is no explicit test for InitNotifier or NotifierExitHandlertest winNotify-1.1 {Tcl_SetTimer: positive timeout} {    set done 0    after 1000 { set done 1 }    vwait done    set done} 1test winNotify-1.2 {Tcl_SetTimer: positive timeout, message pending} {    set x 0    set y 1    set a1 [after 0 { incr y }]    after cancel $a1    after 500 { incr x }    vwait x    list $x $y} {1 1}test winNotify-1.3 {Tcl_SetTimer: cancelling positive timeout} {    set x 0    set y 1    set id [after 10000 { incr y }]    after 0 { incr x }    vwait x    after cancel $id    list $x $y} {1 1}test winNotify-1.4 {Tcl_SetTimer: null timeout, message pending} {    set x 0    set y 1    after 0 { incr x }    after 0 { incr y }    vwait x    list $x $y} {1 2}test winNotify-2.1 {Tcl_ResetIdleTimer} {    set x 0    update    after idle { incr x }    vwait x    set x} 1test winNotify-2.2 {Tcl_ResetIdleTimer: message pending} {    set x 0    set y 1    update    after idle { incr x }    after idle { incr y }    update    list $x $y} {1 2}test winNotify-3.1 {NotifierProc: non-modal normal timer} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after 500 { incr x; testeventloop done }    testeventloop wait    set x} 1test winNotify-3.2 {NotifierProc: non-modal normal timer, rescheduled} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after 500 { incr x; after 100 {incr x; testeventloop done }}    testeventloop wait    set x} 2test winNotify-3.3 {NotifierProc: modal normal timer} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after 500 { incr x }    vwait x    set x} 1test winNotify-3.4 {NotifierProc: modal normal timer, rescheduled} {    update    set x 0    foreach i [after info] {	after cancel $i    }    set y 0    after 500 { incr y; after 100 {incr x}}    vwait x    list $x $y} {1 1}test winNotify-3.5 {NotifierProc: non-modal idle timer} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after idle { incr x; testeventloop done }    testeventloop wait    set x} 1test winNotify-3.6 {NotifierProc: non-modal idle timer, rescheduled} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after idle { incr x; after idle {incr x; testeventloop done }}    testeventloop wait    set x} 2test winNotify-3.7 {NotifierProc: modal idle timer} {    update    set x 0    foreach i [after info] {	after cancel $i    }    after idle { incr x }    vwait x    set x} 1test winNotify-3.8 {NotifierProc: modal idle timer, rescheduled} {    update    set x 0    foreach i [after info] {	after cancel $i    }    set y 0    after idle { incr y; after idle {incr x}}    vwait x    list $x $y} {1 1}# Tcl_DoOneEvent is tested by the timer.test, io.test, and event.test files

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -