use {self::error::Error, super::*};
pub use runestone::Runestone;
pub(crate) use {edict::Edict, etching::Etching, pile::Pile, rune::Rune, rune_id::RuneId};
pub(crate) const CLAIM_BIT: u128 = 1 << 48;
const MAX_DIVISIBILITY: u8 = 38;
pub(crate) const MAX_LIMIT: u128 = 1 << 64;
mod edict;
mod error;
mod etching;
mod pile;
mod rune;
mod rune_id;
mod runestone;
pub mod varint;
type Result<T, E = Error> = std::result::Result<T, E>;
#[cfg(test)]
mod tests {
use {super::*, crate::index::testing::Context};
const RUNE: u128 = 99246114928149462;
#[test]
fn index_starts_with_no_runes() {
let context = Context::builder()
.arg("--index-runes-pre-alpha-i-agree-to-get-rekt")
.build();
context.assert_runes([], []);
}
#[test]
fn default_index_does_not_index_runes() {
let context = Context::builder().build();
context.mine_blocks(1);
context.rpc_server.broadcast_tx(TransactionTemplate {
inputs: &[(1, 0, 0, Witness::new())],
op_return: Some(
Runestone {