Skip to content

Add regression test for #4169#523

Merged
dbkr merged 4 commits into
developfrom
dbkr/e2e_backup_versions_are_numbers
Nov 14, 2018
Merged

Add regression test for #4169#523
dbkr merged 4 commits into
developfrom
dbkr/e2e_backup_versions_are_numbers

Conversation

@dbkr
Copy link
Copy Markdown
Member

@dbkr dbkr commented Nov 9, 2018

Test for matrix-org/synapse#4113

If this fails, it keeps going through the 10 versions which isn't ideal. I tried using the repeat+foreach+while to terminate it but couldn't get it to abort. Feedback welcome on the right runes to make this happen.

@richvdh
Copy link
Copy Markdown
Member

richvdh commented Nov 9, 2018

I think you can do something like:

      try_repeat( sub {
         matrix_create_key_backup( $user );
      }, foreach => [ 0 .. 10 ], while => sub { $_[0] -> is_done } );

whether it's worth doing so, I couldn't say...

@richvdh
Copy link
Copy Markdown
Member

richvdh commented Nov 9, 2018

the code lgtm but I'm not reassured by the failures!

@dbkr
Copy link
Copy Markdown
Member Author

dbkr commented Nov 9, 2018

That's better. Ptal!

Comment thread tests/41end-to-end-keys/07-backup.pl Outdated
test "Can create more than 10 backup versions",
requires => [ $fixture ],

bug => 'synapse/4169',
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this does what you want. It marks the test as an "expected failure".

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume it only does this while the bug is still open though?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'd be wrong :) The string isn't interpreted at all, and certainly doesn't go and check the status of any linked issue (nor is there any consistency in the format of the string)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you're right though

Copy link
Copy Markdown
Member

@richvdh richvdh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@dbkr dbkr merged commit 208a67a into develop Nov 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants