fn search_by_query_returns_rune() {
TestServer::new().assert_redirect("/search?query=ABCD", "/rune/ABCD");
}
#[test]
fn search_by_query_returns_inscription() {
TestServer::new().assert_redirect(
"/search?query=0000000000000000000000000000000000000000000000000000000000000000i0",
"/inscription/0000000000000000000000000000000000000000000000000000000000000000i0",
);
}
#[test]
fn search_is_whitespace_insensitive() {
TestServer::new().assert_redirect("/search/ 0 ", "/sat/0");
}
#[test]
fn search_by_path_returns_sat() {
TestServer::new().assert_redirect("/search/0", "/sat/0");
}
#[test]
fn search_for_blockhash_returns_block() {
TestServer::new().assert_redirect(
"/search/000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f",
"/block/000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f",
);
}
#[test]
fn search_for_txid_returns_transaction() {
TestServer::new().assert_redirect(
"/search/0000000000000000000000000000000000000000000000000000000000000000",