Commit Graph

21 Commits

Author SHA1 Message Date
Your Name
b4836e5329 v2.4.0 2023-07-30 22:08:36 -04:00
Snarling
6732549196
ENUMS: Initial Enum Helper rework + Reorganization (#596) 2023-06-12 00:34:20 -04:00
Snarling
40b89baca1
MISC: Various small fixes (#574)
* ns.ls filter can include leading slash in filename
* scp from terminal accepts multiple filenames
* terminal displays root / instead of ~ as base
* cd with no args returns to root
2023-06-06 08:46:07 -04:00
Snarling
5f2a1c3f27 TERMINAL: Fix original alias syntax (#545) 2023-05-29 06:54:51 -04:00
Snarling
e0272ad4af
FILES: Path rework & typesafety (#479)
* Added new types for various file paths, all in the Paths folder.
* TypeSafety and other helper functions related to these types
* Added basic globbing support with * and ?. Currently only implemented for Script/Text, on nano and download terminal commands
* Enforcing the new types throughout the codebase, plus whatever rewrites happened along the way
* Server.textFiles is now a map
* TextFile no longer uses a fn property, now it is filename
* Added a shared ContentFile interface for shared functionality between TextFile and Script.
* related to ContentFile change above, the player is now allowed to move a text file to a script file and vice versa.
* File paths no longer conditionally start with slashes, and all directory names other than root have ending slashes. The player is still able to provide paths starting with / but this now indicates that the player is specifying an absolute path instead of one relative to root.
* Singularized the MessageFilename and LiteratureName enums
* Because they now only accept correct types, server.writeToXFile functions now always succeed (the only reasons they could fail before were invalid filepath).
* Fix several issues with tab completion, which included pretty much a complete rewrite
* Changed the autocomplete display options so there's less chance it clips outside the display area.
* Turned CompletedProgramName into an enum.
* Got rid of programsMetadata, and programs and DarkWebItems are now initialized immediately instead of relying on initializers called from the engine.
* For any executable (program, cct, or script file) pathing can be used directly to execute without using the run command (previously the command had to start with ./ and it wasn't actually using pathing).
2023-04-24 10:26:57 -04:00
Snarling
fb1f95c26e
VARIOUS: Various changes prior to release 2.2 (#271)
See PR #271 description
2022-12-29 20:28:53 -05:00
Snarling
65cd14e33b
DOC: Add ns documentation for possible sleeve tasks (#217)
* Add specific types for sleeve tasks
* Moved LocationName enum to overall enums file
* Add LocationName enum to those provided to player
* remove trailing s on CompanyPosNames enum (now CompanyPosName, in line with LocationName)
* Also regenerated all ns documentation. This leads to an expected error when checking for generated files, because PRs should not normally touch markdown files. Also leads to a lint failure in generated file bitburner.d.ts
* also removed some exporting from NetscriptDefinitions.d.ts for anything that wasn't imported somewhere else.
2022-11-20 12:07:22 -05:00
Snarling
3addda7173 format and lint 2022-10-01 15:15:36 -04:00
Snarling
9774235404 initial test fix attempt 2022-10-01 15:03:47 -04:00
phyzical
bc5377ba74
fix tests
bugfix/fix-tests

File List:
src/Terminal/determineAllPossibilitiesForTabCompletion.ts
test/jest/Terminal/Directory.test.js
2022-05-25 19:03:58 +08:00
hydroflame
4c33ad444b
Merge pull request #3644 from taralx/patch-1
MISC: fix typing conflict between jest and cypress
2022-05-19 02:13:11 -04:00
Dane Horn
28dad4dd30 expand Directory tests 2022-05-15 09:43:40 +02:00
Dane Horn
1a9d3ee998 clean up regex and adjust tests to new criteria 2022-05-15 09:43:40 +02:00
Dane Horn
0988ec8226 adjust regex for directory name
new regex allows for more flexible folder names, while still disallowing '.' and '..'
2022-05-15 09:43:40 +02:00
JP Sugarbroad
01529a8347 fix typing conflict between jest and cypress
Cypress and Jest both define "expect", but they come from different
libraries (Cypress uses Chai, Jest uses its own thing). So we can't
include both of them in the tsconfig.json. Conveniently, however, we
don't need any of the test code to be part of the main project, so
it suffices to give these things their own tsconfig.json files.

That being done, adding "jest" to the global types lets us remove all
those imports.
2022-05-10 22:26:54 -07:00
hydroflame
c5bc47abf0
Revert "MISC: fix typing conflict between jest and cypress" 2022-05-04 12:14:31 -04:00
JP Sugarbroad
6b7be9f87b fix typing conflict between jest and cypress
Cypress and Jest both define "expect", but they come from different
libraries (Cypress uses Chai, Jest uses its own thing). So we can't
include both of them in the tsconfig.json. Conveniently, however, we
don't need any of the test code to be part of the main project, so
it suffices to give cypress its own tsconfig.json file.

That being done, adding "jest" to the global types lets us remove all
those imports.
2022-04-25 22:10:27 -07:00
Olivier Gagnon
8958046421 fix test 2022-04-12 14:06:24 -04:00
Olivier Gagnon
48f80f25d6 fmt and lint 2022-04-06 19:30:08 -04:00
phyzical
44ea479043 update constants
* added OperationNames
* added faction names
* used citynames where appropriate
2022-03-19 16:09:59 +08:00
Martin Fournier
8e119b2b5b Move cypress & netscript tests to ./test subfolder 2022-01-26 05:35:21 -05:00