Skip to content

Commit a097d08

Browse files
Merge pull request #9938 from guru4elephant/fix_testcase
Fix testcase
2 parents ea41c61 + 83e67be commit a097d08

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

paddle/fluid/framework/program_desc_test.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ TEST(ProgramDesc, copy_ctor) {
6666

6767
for (size_t i = 0; i < global_block->OpSize(); ++i) {
6868
auto op_origin = global_block->Op(i);
69-
auto op_copy = global_block->Op(i);
69+
auto op_copy = global_block_copy->Op(i);
7070

7171
ASSERT_EQ(op_origin->Type(), op_copy->Type());
7272
ASSERT_EQ(op_origin->Inputs(), op_copy->Inputs());
@@ -131,7 +131,7 @@ TEST(ProgramDescBind, serialize_and_deserialize) {
131131

132132
for (size_t i = 0; i < global_block->OpSize(); ++i) {
133133
auto op_origin = global_block->Op(i);
134-
auto op_restored = global_block->Op(i);
134+
auto op_restored = global_block_restored->Op(i);
135135

136136
ASSERT_EQ(op_origin->Type(), op_restored->Type());
137137
ASSERT_EQ(op_origin->Inputs(), op_restored->Inputs());

0 commit comments

Comments
 (0)