Skip to content

Add rspec definitions for riscv payloads#9

Merged
bcoles merged 1 commit into
bcoles:riscv-staged-payloadsfrom
bwatters-r7:fix/add-riscv-rspec-defs
Apr 16, 2026
Merged

Add rspec definitions for riscv payloads#9
bcoles merged 1 commit into
bcoles:riscv-staged-payloadsfrom
bwatters-r7:fix/add-riscv-rspec-defs

Conversation

@bwatters-r7
Copy link
Copy Markdown

I'm getting a little crazy with the rspec inconsistencies. I'm seeing different results running things on Github and locally, and non-deterministic behavior all-around.
It does not help that the fix here is not considered a test failure (and is not listed as a failure), but is an error that will cause the tests to fail 😞
Locally, this change makes the branch pass (and also not error). I simply fail to understand why Github testing is complaining about payload cache size for windows payloads:

    0.83565 seconds ./spec/support/shared/examples/payload_cached_size_is_consistent.rb:113
  modules/payloads windows/shell/reverse_tcp_rc4 it should behave like payload cached size is consistent windows/shell/reverse_tcp_rc4 has a valid cached_size

Anyway, this PR fixes the error in rspec so even though everything passes, the tests will pass:

An error occurred in an `after(:context)` hook.
Failure/Error: expect(missing_ancestor_reference_name_set).to be_empty, "Some payloads are untested: #{missing_ancestor_reference_name_set.join(', ')}. Please update `modules/payloads_spec.rb` with the payload definitions"
  Some payloads are untested: stagers/linux/riscv32le/bind_tcp, stagers/linux/riscv32le/reverse_tcp, stagers/linux/riscv64le/bind_tcp, stagers/linux/riscv64le/reverse_tcp, stages/linux/riscv32le/shell, stages/linux/riscv64le/shell. Please update `modules/payloads_spec.rb` with the payload definitions
# ./spec/support/shared/contexts/untested_payloads.rb:62:in `block (2 levels) in <top (required)>'
...
Finished in 8 minutes 36 seconds (files took 9.15 seconds to load)
18794 examples, 0 failures, 33 pending, 1 error occurred outside of examples

Thanks for listening to me rant, and thank you for being patient.

@bcoles bcoles merged commit bfe1124 into bcoles:riscv-staged-payloads Apr 16, 2026
16 of 17 checks passed
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.

2 participants