Skip to content

Commit

Permalink
tests update
Browse files Browse the repository at this point in the history
  • Loading branch information
vo-nil committed May 23, 2024
1 parent 866bf10 commit 5f4b654
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 13 deletions.
11 changes: 5 additions & 6 deletions test/systems/plonk/placeholder/circuits.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ namespace nil {
namespace crypto3 {
namespace zk {
namespace snark {
template<typename FieldType, typename ParamsType, std::size_t usable_rows_amount>
template<typename FieldType, typename ParamsType>
class circuit_description {
typedef zk::snark::detail::placeholder_policy<FieldType, ParamsType> policy_type;

Expand All @@ -63,7 +63,7 @@ namespace nil {

public:
std::size_t table_rows;
std::size_t usable_rows = usable_rows_amount;
std::size_t usable_rows;

typename policy_type::variable_assignment_type table;

Expand Down Expand Up @@ -96,14 +96,12 @@ namespace nil {
const std::size_t rows_amount_1 = 13;

template<typename FieldType>
circuit_description<FieldType, placeholder_circuit_params<FieldType>, rows_amount_1> circuit_test_1(
circuit_description<FieldType, placeholder_circuit_params<FieldType>> circuit_test_1(
typename nil::crypto3::random::algebraic_engine<FieldType> alg_rnd = nil::crypto3::random::algebraic_engine<FieldType>(),
boost::random::mt11213b rnd = boost::random::mt11213b()
) {
using assignment_type = typename FieldType::value_type;

constexpr static const std::size_t usable_rows = rows_amount_1;

constexpr static const std::size_t witness_columns = witness_columns_1;
constexpr static const std::size_t public_columns = public_columns_1;
constexpr static const std::size_t constant_columns = constant_columns_1;
Expand All @@ -112,7 +110,8 @@ namespace nil {
witness_columns + public_columns + constant_columns;

typedef placeholder_circuit_params<FieldType> circuit_params;
circuit_description<FieldType, circuit_params, usable_rows> test_circuit;
circuit_description<FieldType, circuit_params> test_circuit;
test_circuit.usable_rows = rows_amount_1;
std::vector<std::vector<typename FieldType::value_type>> table(table_columns);

std::vector<typename FieldType::value_type> q_add(test_circuit.usable_rows);
Expand Down
7 changes: 0 additions & 7 deletions test/systems/plonk/placeholder/placeholder_circuits.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,6 @@ struct placeholder_test_runner {
using field_type = FieldType;

struct placeholder_test_params {
constexpr static const std::size_t usable_rows = 13;

constexpr static const std::size_t witness_columns = WitnessColumns;
constexpr static const std::size_t public_input_columns = PublicInputColumns;
constexpr static const std::size_t constant_columns = ConstantColumns;
constexpr static const std::size_t selector_columns = SelectorColumns;

constexpr static const std::size_t lambda = 40;
constexpr static const std::size_t m = 2;
};
Expand Down

0 comments on commit 5f4b654

Please sign in to comment.