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

Simple sessions #13

Merged
merged 7 commits into from
Aug 23, 2017
Merged

Simple sessions #13

merged 7 commits into from
Aug 23, 2017

Conversation

michaeldfallen
Copy link
Contributor

This PR adds simple session management using express session, with some extra functionality implemented by shimming the functions on the req.session and req.sessionStore.

Goals for sessions:

  • -Ability to explicitly create a session- - Complete, provided by req.session.generate()
  • Middleware / Step to create a session - todo
  • -Ability to enforce that a session- - Complete, provided by req.session.active()
  • Middleware to enforce a session - todo
  • Middleware / Exit step to destroy a session - todo
  • Per record encryption - to do

@codecov-io
Copy link

codecov-io commented Aug 22, 2017

Codecov Report

Merging #13 into master will increase coverage by 0.82%.
The diff coverage is 98.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #13      +/-   ##
==========================================
+ Coverage   98.41%   99.23%   +0.82%     
==========================================
  Files           6        7       +1     
  Lines          63      131      +68     
==========================================
+ Hits           62      130      +68     
  Misses          1        1
Impacted Files Coverage Δ
src/services/sessions/shims.js 100% <100%> (ø)
src/Journey.js 100% <100%> (ø) ⬆️
src/services/sessions.js 97.56% <97.36%> (+3.44%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f49fa12...7ed6b21. Read the comment docs.

@michaeldfallen
Copy link
Contributor Author

@KarolJastrzebski can you make codecov use the .eslintrc.json config from the repo? 27 comments that conflict with my local linting.

@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@hmcts hmcts deleted a comment Aug 23, 2017
@michaeldfallen michaeldfallen merged commit b72680b into master Aug 23, 2017

const app = express();

const baseUrl = `http://localhost:${config.port}`;
Copy link
Contributor

Choose a reason for hiding this comment

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

perhaps pull domain from config also?

@michaeldfallen michaeldfallen deleted the simple-sessions branch August 31, 2017 12:46
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