mirror of
https://github.com/troglobit/editline.git
synced 2025-05-06 04:21:24 +08:00
testit: Test new rl_uninitialize() and load/store history
Signed-off-by: Claus Fischer <claus.fischer@clausfischer.com> Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
parent
317b43e488
commit
91937d970d
@ -45,6 +45,8 @@ int main(int argc, char *argv[] __attribute__ ((unused)))
|
|||||||
int doit;
|
int doit;
|
||||||
char *prompt, *p;
|
char *prompt, *p;
|
||||||
|
|
||||||
|
read_history(".testit_history");
|
||||||
|
|
||||||
doit = argc == 1;
|
doit = argc == 1;
|
||||||
if ((prompt = getenv("TESTPROMPT")) == NULL)
|
if ((prompt = getenv("TESTPROMPT")) == NULL)
|
||||||
prompt = "testit> ";
|
prompt = "testit> ";
|
||||||
@ -63,6 +65,9 @@ int main(int argc, char *argv[] __attribute__ ((unused)))
|
|||||||
free(p);
|
free(p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
write_history(".testit_history");
|
||||||
|
rl_uninitialize();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user