makersacademy / problem-solving

For problem-solving during the PreCourse
6 stars 2 forks source link

cannot load such file -- mastery_answer_code_quality #171

Closed CKKH closed 6 years ago

CKKH commented 6 years ago

Hey all

I'm having issues running tests on my solutions where the specs require "mastery_answer_code_quality".

When I run rspec on my solution, I'm getting the following feedback via my terminal:

`An error occurred while loading ./spec/question_1_spec.rb. Failure/Error: require "mastery_answer_code_quality"

LoadError: cannot load such file -- mastery_answer_code_quality

./spec/question_1_spec.rb:1:in `<top (required)>'

No examples found.

Finished in 0.00023 seconds (files took 0.09448 seconds to load) 0 examples, 0 failures, 1 error occurred outside of examples`

As per instructions on https://github.com/makersacademy/mastery-quizzes/blob/master/fixing_problems.md, I took the following steps:

"I get an error saying cannot load such file -- mastery_answer_code_quality

mastery_answer_code_quality is a gem that is installed when you run bundle install.

Run bundle install to install it."

I've checked the gem is in my Gemfile, which it is on line 12:

gem 'mastery_answer_code_quality', :git => 'https://github.com/makersacademy/mastery_answer_code_quality.git'

When I run bundle install, this outputs to my terminal:

Using rake 12.3.1 Using public_suffix 3.0.3 Using addressable 2.5.2 Using ast 2.4.0 Using bundler 1.17.1 Using ffi 1.9.25 Using childprocess 0.9.0 Using safe_yaml 1.0.4 Using crack 0.4.3 Using diff-lcs 1.3 Using hashdiff 0.3.7 Using multi_xml 0.6.0 Using httparty 0.16.2 Using mastery_answer_code_quality 0.1.0 from https://github.com/makersacademy/mastery_answer_code_quality.git (at master@bd71ed2) Using parallel 1.12.1 Using parser 2.5.3.0 Using powerpack 0.1.2 Using rainbow 3.0.0 Using rspec-support 3.8.0 Using rspec-core 3.8.0 Using rspec-expectations 3.8.2 Using rspec-mocks 3.8.0 Using rspec 3.8.0 Using ruby-progressbar 1.10.0 Using unicode-display_width 1.4.0 Using rubocop 0.52.0 Using safe_ruby 1.0.4 Using webmock 3.4.2 Bundle complete! 7 Gemfile dependencies, 28 gems now installed. Usebundle info [gemname]to see where a bundled gem is installed.

The output from running bundle info mastery_answer_code_quality is:

* mastery_answer_code_quality (0.1.0 bd71ed2) Summary: Uses Rubocop to assess quality of mastery learning answers Path: /home/ckkh/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/bundler/gems/mastery_answer_code_quality-bd71ed232f28

For reference my operating system is Ubuntu 18.04.1 LTS and I can confirm I'm using Ruby 2.2.3.

Anybody else experiencing this?

I've attached a screenshot of the terminal outputs discussed.

Thanks

Chris

screenshot from 2018-11-05 16-25-36