Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move code out of spec_helper #29

Open
jgebal opened this issue Nov 19, 2015 · 6 comments
Open

Move code out of spec_helper #29

jgebal opened this issue Nov 19, 2015 · 6 comments

Comments

@jgebal
Copy link
Contributor

jgebal commented Nov 19, 2015

If the connection management details would be moved from spec_helper into the library, so that the spec_helper is responsible for managing connections, then the coverage reporter could reference the connection list and perform operations on it.

Any cons of such refactoring?

@javornikolov
Copy link
Collaborator

I'm not very deep into coverage internals yet. How is currently the coverage connection being managed?

@jgebal
Copy link
Contributor Author

jgebal commented Nov 21, 2015

Currently one coverage reporter operates on a single connection alias.

@javornikolov
Copy link
Collaborator

How does reporter know which connection alias to work on?

@jgebal
Copy link
Contributor Author

jgebal commented Nov 23, 2015

Currently it's a bit dirty.
Your local project spec_helper.rb is controlling it.
The local project spec_helper is uncovering the ruby-plsql-spec library internals by referencing env parameters used by library and by controlling how the coverage report is done.
https://github.com/rsim/ruby-plsql-spec/blob/master/lib/plsql/spec/templates/spec/spec_helper.rb

@javornikolov
Copy link
Collaborator

OK, I see now

PLSQL::Coverage.start(name)

We're iterating over all connections and we're invoking the above for each connection alias name. I guess we can pass a list of connection names if we really need ability to work on a whole list.

So.. What's your idea for refactoring?

@jgebal
Copy link
Contributor Author

jgebal commented Nov 24, 2015

Hard to explain. I'll make changes in a branch and share.
On 23 Nov 2015 22:13, "Yavor Nikolov" notifications@github.com wrote:

OK, I see now

PLSQL::Coverage.start(name)

We're iterating over all connections and we're invoking the above for each
connection alias name. I guess we can pass a list of connection names if we
really need ability to work on a whole list.

So.. What's your idea for refactoring?


Reply to this email directly or view it on GitHub
#29 (comment)
.

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

No branches or pull requests

2 participants