2016-03-02 18:05:08 +03:00
/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*-
*
* Copyright ( C ) 2016 Red Hat , Inc .
*
* This library is free software ; you can redistribute it and / or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation ; either
* version 2 of the License , or ( at your option ) any later version .
*
* This library 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
* Lesser General Public License for more details .
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library ; if not , write to the
* Free Software Foundation , Inc . , 59 Temple Place - Suite 330 ,
* Boston , MA 02111 - 1307 , USA .
*/
# include "config.h"
# include <stdlib.h>
# include <gio/gio.h>
# include <string.h>
# include "libglnx.h"
# include "libostreetest.h"
static void
test_repo_is_not_system ( gconstpointer data )
{
2016-03-03 21:49:54 +03:00
OstreeRepo * repo = ( void * ) data ;
g_assert ( ! ostree_repo_is_system ( repo ) ) ;
2016-03-02 18:05:08 +03:00
}
int main ( int argc , char * * argv )
{
g_autoptr ( GError ) error = NULL ;
2016-03-03 21:49:54 +03:00
glnx_unref_object OstreeRepo * repo = NULL ;
2016-03-02 18:05:08 +03:00
g_test_init ( & argc , & argv , NULL ) ;
2016-03-03 21:49:54 +03:00
repo = ot_test_setup_repo ( NULL , & error ) ;
if ( ! repo )
2016-03-02 18:05:08 +03:00
goto out ;
2016-03-03 21:49:54 +03:00
g_test_add_data_func ( " /repo-not-system " , repo , test_repo_is_not_system ) ;
2016-03-02 18:05:08 +03:00
return g_test_run ( ) ;
out :
if ( error )
g_error ( " %s " , error - > message ) ;
return 1 ;
}