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

Scope globally declared variables to root describe #5934

Closed
ManuGowda opened this issue Oct 29, 2020 · 0 comments · Fixed by #5973
Closed

Scope globally declared variables to root describe #5934

ManuGowda opened this issue Oct 29, 2020 · 0 comments · Fixed by #5973
Assignees
Milestone

Comments

@ManuGowda
Copy link
Contributor

ManuGowda commented Oct 29, 2020

Description

Move globally declared variables and functions to root describe

Defining variables globally

const testData = {};
describe('fee', () => {
  describe('nested', () => {
    it.todo('should assert something');
  });
});

scoped to root describe

describe('fee', () => {
  const testData = {};
  describe('nested', () => {
    it.todo('should assert something');
  });
});

Motivation

  • To be compliance with Lisk coding standards

Acceptance Criteria

  • Move all globally declared variables root describe
  • Nested function functions specific to a particular function shouldn't be scoped outside
@ManuGowda ManuGowda changed the title Scope globally declared variables and functions to root describe Scope globally declared variables to root describe Oct 29, 2020
@sridharmeganathan sridharmeganathan added this to the Sprint 32 milestone Nov 9, 2020
ManuGowda added a commit that referenced this issue Nov 13, 2020
Scope globally declared variables to root describe - Closes #5934
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants