Commit Graph

326 Commits

Author SHA1 Message Date
Buck Doyle
458a6c413d Remove inverse block for list-pagination (#6523)
As the angle bracket invocation RFC says:

> There is no dedicated syntax for passing an "else" block
> directly. If needed, that can be passed using the named
> blocks syntax.

https://github.com/emberjs/rfcs/blob/master/text/0311-angle-bracket-invocation.md#block

Unfortunately, using a contextual component doesn’t help as
the yield inside that component will still result in content
rendering that would show when the source isn’t empty. So
we decided to change the interface so you have to check
whether the source is empty before using it, which aligns with
how list-table works.
2019-10-24 07:05:43 -05:00
Buck Doyle
882a0210fe UI: Update Ember to 3.12 LTS (#6419)
This is mostly deprecation fixes and blueprint changes. There
are some dependency updates too; the changes to Ember
Basic Dropdown necessitated changing it to angle bracket
component invocation. The conversion of the rest of the
templates will happen separately.
2019-10-15 13:32:58 -05:00
Buck Doyle
550e1b1a1e UI: Change Mirage data to be stable in development (#6389)
This sets a default-but-query-configurable Faker seed in development,
via faker-seed. It also changes uses of Math.random to use Faker’s
randomness so auto-generated data remains stable in development.
2019-10-03 09:13:08 -05:00
Buck Doyle
7fcfdab316 UI: Update Mirage to 1.1.2 (#6166) 2019-09-26 13:47:07 -05:00
Buck Doyle
e3d8e73124 UI: Restore proxy tag tests (#6360)
The recurring problem here was that sometimes the factories would
generate more than one task, and it was random whether the task
with the proxy task would be the first in the list. This ensures
that the proxy task is always first so the tests can run again.
2019-09-26 11:50:01 -05:00
Buck Doyle
9272cca7ab UI: Remove proxy tag tests again (#6359)
I thought #6343 would fix the flapping but it didn’t 😞
2019-09-20 15:27:33 -05:00
Buck Doyle
05fd8a068c UI: Fix Connect proxy tag (#6343)
This fixes a race condition in the pseudo-relationship between a
TaskState and a Task that was causing the Consul Connect proxy tag
to sometimes show on the wrong task. There’s no direct Ember Data-style
relationship between a TaskState and its Task; instead, it’s determined
by searching for a Task with the matching name. The related Task was
sometimes stored before everything was ready and not recalculated when
the name became known. This ensures the relationship is accurate if the
TaskState’s name property changes.
2019-09-19 08:09:49 -05:00
Buck Doyle
e41a7f6765 UI: Remove Connect proxy tag tests again (#6284)
This semi-reverts #6275, as the tests are intermittently
failing in CI.
2019-09-05 14:34:47 -05:00
Buck Doyle
801cb32d07 UI: Restore Connect proxy tag tests (#6275)
These are the tests skipped in #6271.
2019-09-05 14:09:32 -05:00
Buck Doyle
97150f9f42 UI: Move kind property to task (#6271)
I put this property in the wrong place. 

I’ve found how to fix the mock API in the tests but
they’re failing to pass with headless Chrome only,
so they’re skipped for now.
2019-09-05 13:14:54 -05:00
Buck Doyle
b29d88556b Add handling for not-running task filesystem query (#6267) 2019-09-04 17:38:26 -05:00
Buck Doyle
dfb88cc787 UI: add Consul Connect features (#6108) 2019-09-04 09:39:56 -05:00
Buck Doyle
2364fb2da1 UI: Add creation time to evaluations table (#6050) 2019-08-22 08:11:24 -05:00
Michael Lange
c29d836dd9 Merge pull request #5871 from hashicorp/f-ui/alloc-fs
UI: Allocation file system explorer
2019-08-20 10:18:23 -07:00
Michael Lange
65aa4757b8 Use the standard empty state when a dir is empty 2019-08-19 17:16:26 -07:00
Michael Lange
354da0f60c Merge pull request #6048 from hashicorp/f-ui/alloc-fs-files
UI: Alloc FS: File Viewer
2019-08-19 10:36:28 -07:00
Michael Lange
a321145457 Encode characters in file paths to ensure proper URIs 2019-08-14 12:54:11 -07:00
Buck Doyle
a8c90f5352 Fix navigation via clicking recent allocation row (#6087)
This fixes the recent allocation rows to navigate when clicking within them
rather than just on the link, which matches the cursor behaviour.
2019-08-08 09:26:46 -05:00
Michael Lange
ed55a7b09a Test that the client is contacted correctly, and the server is used as a fallback 2019-08-07 17:35:43 -07:00
Michael Lange
e97c91191c Use a data-uri instead of an image for the image-file-test 2019-08-07 15:08:38 -07:00
Buck Doyle
473ef7a662 Add page titles to filesystem routes (#6024) 2019-08-01 11:17:46 -05:00
Michael Lange
e277cc5308 Update factory-based fs tests to sort properly 2019-07-31 01:41:00 -07:00
Michael Lange
be5c88fd4f Remove errant server logging line 2019-07-31 01:40:39 -07:00
Michael Lange
c4516158b0 Test coverage for task-file component 2019-07-30 17:25:49 -07:00
Michael Lange
6bd54f7343 Test coverage for streaming file component 2019-07-30 17:25:48 -07:00
Michael Lange
7294f38a32 Integration tests for the image-file component 2019-07-30 17:25:47 -07:00
Michael Lange
8f496e8b65 Refactor existing fs tests to use new mirage factories 2019-07-30 17:25:46 -07:00
Michael Lange
07f1c89cc5 Use the stream decode util and never opt to use the plain query param 2019-07-30 17:22:45 -07:00
Michael Lange
a21ae52783 Move common stream frame decoding to a util 2019-07-30 17:22:44 -07:00
Buck Doyle
2152d57df3 UI: Add IPv6 bracket-wrapping to network serializer (#6007)
This addresses the issue raised by @pznamensky in #5966.
2019-07-30 16:58:01 -05:00
Buck Doyle
c0ba4eeac9 Merge branch 'master' into f-ui/alloc-fs
# Conflicts:
#	ui/app/templates/allocations/allocation/task/index.hbs
#	ui/app/templates/allocations/allocation/task/logs.hbs
2019-07-26 14:49:36 -05:00
Buck Doyle
f046ec31e5 UI: Add allocation directory sorting (#5914)
When sorting by size, directories are sorted by name, as size
isn’t displayed.

This includes a change to the positioning of sort arrows for all tables,
moving them closer to the text, because in some cases, the arrows
for right-aligned columns were ambiguously positioned.
2019-07-23 15:37:34 -05:00
Buck Doyle
1147fd6278 UI: Remove ember-native-dom-helpers (#5959)
This also includes migration of some tests to async.
2019-07-23 14:40:32 -05:00
Buck Doyle
87d716ed0b UI: Add page titles (#5924)
This uses ember-page-title to add dynamic page titles throughout the
route hierarchy. When there’s more than one region, the current
current region is added before the final entry of “- Nomad”.
2019-07-17 15:02:58 -05:00
Buck Doyle
596b5aaf7e UI: Add copy button for client/allocation UUIDs (#5926)
The button shows a success icon and tooltip on click, and resets
after two seconds.
2019-07-15 12:14:32 -05:00
Buck Doyle
fdca5cf84a Remove superfluous test attributes (#5927)
I found while working on #5926 that x-icon already adds
assertion-compatible selectors, so these wrappers are
unnecessary.
2019-07-08 10:36:56 -05:00
Buck Doyle
ee07bab099 UI: Add allocation directory rendering (#5873)
This lets users navigate the allocation filesystem. It doesn’t
support viewing actual files yet.
2019-07-02 16:42:38 -05:00
Michael Lange
d39d0f04c3 Test support and coverage for fs routing 2019-06-20 15:20:15 -07:00
Buck Doyle
237c40698b Update client list to combine statuses (#5789)
The draining, eligibility, and status fields now all show under a combined
state column. Draining takes precedence, then (in)eligibility; if neither of
those is true, the status displays.
2019-06-19 10:11:17 -07:00
Michael Lange
afa5f4dc0e Include the _ prefix separator in both regexes
And include all prefix types in the test data
2019-05-21 14:20:40 -07:00
Michael Lange
20028361c1 Use the TwoStepButton page object for integration testing too 2019-05-21 09:24:19 -07:00
Michael Lange
d33f4bfd49 Acceptance testing for allocation lifecycle 2019-05-21 09:24:19 -07:00
Michael Lange
69c6c34afa Support task restarting in the allocation adapter 2019-05-21 09:24:17 -07:00
Michael Lange
b41af1c67a Add cancel on click outside and disabled behaviors to two-step-button 2019-05-21 09:24:14 -07:00
Michael Lange
203b54b246 Move addToPath to its own util 2019-05-20 11:52:47 -07:00
Michael Lange
3c1de2df91 Standardize on Abort over Cancel 2019-05-20 11:08:16 -07:00
Michael Lange
c68962078a Replace the adapter cancellation methods with a cancellation token system 2019-05-20 10:29:22 -07:00
Michael Lange
f88c4d7648 Fixed flaky client-detail test
Since one allocation is preempted, the alloc factory creates a new alloc
that wasn't guaranteed to be running. When it is the first alloc row in
the table, then the alloc row detail test fails because non-running
allocs don't have metrics. The fix was to manually update all the alloc
clientStatuses.
2019-05-09 10:26:55 -07:00
Conor Mongey
aa4c1288f3 Return a htmlSafe string rather than use triple curlies 2019-05-02 21:47:24 +01:00
Michael Lange
4166a715fb Updated serializer unit tests 2019-04-22 17:20:52 -07:00