2014-04-17 23:55:49 +02:00
|
|
|
# ngIRCd test suite
|
|
|
|
# Channel test
|
2002-09-09 12:16:24 +02:00
|
|
|
|
2014-04-17 23:57:38 +02:00
|
|
|
spawn telnet 127.0.0.1 6789
|
2002-09-09 12:16:24 +02:00
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"Connected"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "nick nick\r"
|
|
|
|
send "user user . . :User\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"376"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "join #channel\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2003-12-27 14:01:12 +01:00
|
|
|
"@* JOIN :#channel"
|
2002-09-09 12:16:24 +02:00
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"366"
|
|
|
|
}
|
|
|
|
|
2002-09-09 23:26:00 +02:00
|
|
|
send "topic #channel :Test-Topic\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2003-12-27 14:01:12 +01:00
|
|
|
"@* TOPIC #channel :Test-Topic"
|
2002-09-09 23:26:00 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
send "who #channel\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2003-12-27 14:01:12 +01:00
|
|
|
"352 nick #channel"
|
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"* nick H@ :0 User"
|
2002-09-09 23:26:00 +02:00
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"315 nick #channel"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "names #channel\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"353 nick = #channel :@nick"
|
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"366 nick #channel"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "list\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"322 nick #channel 1 :Test-Topic"
|
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"323 nick :End of LIST"
|
|
|
|
}
|
|
|
|
|
2015-03-14 11:13:50 +01:00
|
|
|
send "part #channel :bye bye\r"
|
2002-09-09 12:16:24 +02:00
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2015-03-14 11:13:50 +01:00
|
|
|
"@* PART #channel :bye bye"
|
2002-09-09 12:16:24 +02:00
|
|
|
}
|
|
|
|
|
2008-02-05 14:31:50 +01:00
|
|
|
send "join #channel\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"@* JOIN :#channel"
|
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"366"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "join #channel2\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"@* JOIN :#channel2"
|
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"366"
|
|
|
|
}
|
|
|
|
|
|
|
|
send "join 0\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2015-03-14 11:13:50 +01:00
|
|
|
"@* PART #channel2 :"
|
2008-02-05 14:31:50 +01:00
|
|
|
}
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
2015-03-14 11:13:50 +01:00
|
|
|
"@* PART #channel :"
|
2008-02-05 14:31:50 +01:00
|
|
|
}
|
|
|
|
|
2002-09-09 12:16:24 +02:00
|
|
|
send "quit\r"
|
|
|
|
expect {
|
|
|
|
timeout { exit 1 }
|
|
|
|
"Connection closed"
|
|
|
|
}
|