split dump_demo to steps for better reuse.