Opened 8 years ago

Last modified 20 months ago

#4098 new defect

[PATCH] UnitAI tests

Reported by: elexis Owned by:
Priority: Nice to Have Milestone: Backlog
Component: Simulation Keywords: rfc patch
Cc: Patch:

Description

UnitAI has many code style issues, for example bad linebreaks, uses deprecated for each, variables out of scope, redeclared variables and the like that ought to be fixed. Most of them can be found using jshint. We must be very careful to not introduce oversights as UnitAI is a weird monster with 6000 lines of code and many edge cases.

Attachments (4)

4098.diff (19.9 KB ) - added by Stan 8 years ago.
Modest proposal
4098.1.diff (20.7 KB ) - added by Stan 8 years ago.
Some more fat arrow functions, further simplification
4098.2.diff (21.1 KB ) - added by Stan 8 years ago.
Fix the above
4098.3.diff (20.5 KB ) - added by Stan 7 years ago.
I fixed the above. About the tests I really don't know what to do for that.

Download all attachments as: .zip

Change History (12)

comment:1 by Stan, 8 years ago

Keywords: review patch added
Milestone: BacklogAlpha 21
Owner: set to Stan
Status: newassigned
Summary: UnitAI code style fixes[PATCH] UnitAI code style fixes

by Stan, 8 years ago

Attachment: 4098.diff added

Modest proposal

by Stan, 8 years ago

Attachment: 4098.1.diff added

Some more fat arrow functions, further simplification

by Stan, 8 years ago

Attachment: 4098.2.diff added

Fix the above

comment:3 by sanderd17, 8 years ago

Keywords: rfc added; review removed

Most changes seem good, however, per the new guidelines, you should also write tests for modified code in the simulation, see SubmittingPatches

Also, those if-lines shouldn't be made longer, though the && can be moved to the end of the lines instead of the beginning.

comment:4 by Itms, 8 years ago

Keywords: rfc removed

Any news? Moving out of the queue since comments have been made by Sander.

comment:5 by elexis, 8 years ago

Milestone: Alpha 21Backlog
Summary: [PATCH] UnitAI code style fixes[PATCH] UnitAI tests

by Stan, 7 years ago

Attachment: 4098.3.diff added

I fixed the above. About the tests I really don't know what to do for that.

comment:6 by Stan, 7 years ago

Keywords: rfc added
Milestone: BacklogWork In Progress

comment:7 by Imarok, 5 years ago

Component: UI & SimulationSimulation

Move tickets to Simulation as UI & Simulation got some sub components.

comment:8 by Stan, 20 months ago

Milestone: Work In ProgressBacklog
Owner: Stan removed
Status: assignednew

No progress in a while

Note: See TracTickets for help on using tickets.