Branch data Line data Source code
1 : : /****************************************************************************** 2 : : * This file is part of the cvc5 project. 3 : : * 4 : : * Copyright (c) 2009-2026 by the authors listed in the file AUTHORS 5 : : * in the top-level source directory and their institutional affiliations. 6 : : * All rights reserved. See the file COPYING in the top-level source 7 : : * directory for licensing information. 8 : : * **************************************************************************** 9 : : * 10 : : * A simple start-up/tear-down test for cvc5. 11 : : * 12 : : * This simple test just makes sure that the public interface is 13 : : * minimally functional. It is useful as a template to use for other 14 : : * system tests. 15 : : */ 16 : : 17 : : #include <cvc5/c/cvc5.h> 18 : : 19 : 1 : int main() 20 : : { 21 : 1 : Cvc5TermManager* tm = cvc5_term_manager_new(); 22 : 1 : Cvc5* solver = cvc5_new(tm); 23 : : 24 : 1 : Cvc5Term assumptions[1] = {cvc5_mk_false(tm)}; 25 : 1 : Cvc5Result r = cvc5_check_sat_assuming(solver, 1, assumptions); 26 : 1 : int res = cvc5_result_is_unsat(r) ? 0: 1; 27 : 1 : cvc5_delete(solver); 28 : 1 : cvc5_term_manager_delete(tm); 29 : 1 : return res; 30 : : } 31 : :