/*
Copyright (C) 2017 Red Hat
SSSD tests: Test KCM JSON marshalling
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "config.h"
#include <stdio.h>
#include <popt.h>
#include "util/util_creds.h"
#include "responder/kcm/kcmsrv_ccache.h"
#include "responder/kcm/kcmsrv_ccache_be.h"
#include "tests/cmocka/common_mock.h"
struct kcm_marshalling_test_ctx {
};
{
assert_int_equal(kerr, 0);
assert_int_equal(kerr, 0);
return 0;
}
{
struct kcm_marshalling_test_ctx);
return 0;
}
struct kcm_ccache *cc2)
{
}
struct kcm_ccache *cc2)
{
assert_int_equal(ret, 0);
}
struct kcm_ccache *cc2)
{
char *name1;
char *name2;
assert_int_equal(kerr, 0);
assert_int_equal(kerr, 0);
}
struct kcm_ccache *cc2)
{
}
struct kcm_ccache *cc2)
{
}
{
struct kcm_marshalling_test_ctx);
const char *url;
const char *name;
const char *key;
&owner,
name,
&cc);
cc,
&owner,
&url,
&payload);
key,
(const char *) data,
&owner,
&cc2);
/* This key is exactly one byte shorter than it should be */
TEST_UUID_STR"-",
(const char *) data,
&owner,
&cc2);
}
{
}
{
const char *name;
}
{
}
{
int opt;
int rv;
};
};
/* Set debug level to invalid value so we can decide if -d 0 was used. */
switch(opt) {
default:
return 1;
}
}
/* Even though normally the tests should clean up after themselves
* they might not after a failed run. Remove the old DB to be sure */
return rv;
}