blob: a7f7dd4e96a146ccf1495876d80a9059a15fe1b4 [file] [log] [blame]
Bert Frees111e7022015-02-10 12:57:05 +01001#include <stdio.h>
2#include <string.h>
3#include <stdlib.h>
4#include <unistd.h>
5#include "louis.h"
6
7int
8main(int argc, char **argv)
9{
10 int success = 0;
11 char * match;
Bert Frees17a7ad12015-03-09 20:41:05 +010012 const char * tables[] = {"tablesWithMetadata/foo","tablesWithMetadata/bar",NULL};
Bert Frees111e7022015-02-10 12:57:05 +010013 lou_setLogLevel(LOG_DEBUG);
Bert Frees17a7ad12015-03-09 20:41:05 +010014 lou_indexTables(tables);
Bert Frees111e7022015-02-10 12:57:05 +010015 match = lou_findTable("id:foo");
16 success |= (!match || strcmp(match, "tablesWithMetadata/foo"));
17 match = lou_findTable("language:en");
18 success |= (!match || strcmp(match, "tablesWithMetadata/bar"));
19 return success;
20}