Skip to content

Commit

Permalink
Merge branch 'main' of github.com:evergreen-ci/ui into dependabot/npm…
Browse files Browse the repository at this point in the history
…_and_yarn/leafygreen-ui/segmented-control-8.2.11
  • Loading branch information
SupaJoon committed Apr 12, 2024
2 parents cf738c1 + 01ef091 commit 801694d
Show file tree
Hide file tree
Showing 213 changed files with 3,798 additions and 1,937 deletions.
2 changes: 1 addition & 1 deletion .evergreen/attach.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,4 +167,4 @@ functions:
command: attach.xunit_results
params:
files:
- "./ui/${app_dir}/bin/jest/*.xml"
- "./ui/bin/jest/*.xml"
14 changes: 7 additions & 7 deletions .evergreen/shared.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,21 +67,21 @@ functions:
params:
working_dir: ui/logkeeper
background: true
script: go run main/logkeeper.go --localPath _bucketdata
script: go run main/logkeeper.go --localPath ../evergreen/_bucketdata
shell: bash
env:
GOROOT: ${goroot}
PATH: ${goroot}/bin:$PATH
LK_CORS_ORIGINS: http:\/\/localhost:\d+

seed-logkeeper:
seed-bucket-data:
command: s3.get
type: setup
params:
aws_key: ${AWS_ACCESS_KEY_ID}
aws_secret: ${AWS_SECRET_ACCESS_KEY}
aws_session_token: ${AWS_SESSION_TOKEN}
extract_to: ui/logkeeper
extract_to: ui/evergreen
remote_file: _bucketdata.tar.gz
bucket: parsley-test

Expand Down Expand Up @@ -310,10 +310,10 @@ functions:
yarn-test:
command: shell.exec
params:
working_dir: ui/${app_dir}
working_dir: ui
script: |
${PREPARE_SHELL}
yarn test --ci --testPathIgnorePatterns=snapshot.test.ts
yarn test --ci --testPathIgnorePatterns=snapshot.test.ts --selectProjects ${build_variant}
yarn-tsc:
command: shell.exec
Expand Down Expand Up @@ -361,7 +361,7 @@ tasks:
- func: run-make-background
vars:
target: local-evergreen
- func: seed-logkeeper
- func: seed-bucket-data
- func: run-logkeeper
- func: yarn-build
- func: yarn-preview
Expand All @@ -376,7 +376,7 @@ tasks:
vars:
target: local-evergreen
- func: symlink
- func: seed-logkeeper
- func: seed-bucket-data
- func: run-logkeeper
- func: yarn-build
- func: yarn-serve
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
node_modules

# artifacts
bin
2 changes: 2 additions & 0 deletions .graphqlrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
schema: "apps/*/sdlschema/**/*.graphql"
documents: "apps/*/**/src/gql/**/*.graphql"
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
yarn lint-staged
34 changes: 34 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,37 @@
# Evergreen UI

The new home of [Spruce](/apps/spruce) and [Parsley](/apps/parsley).

## Monorepo Tips & Tricks

Check out the [Yarn Workspaces documentation](https://classic.yarnpkg.com/lang/en/docs/workspaces/) for more.

### Upgrades

To upgrade a dependency across workspaces:

```bash
yarn upgrade-interactive [--latest] [package-name]
```

### Scripts

To run a script in a workspace from root:

```bash
yarn workspace [workspace-name] run [script-name]
```

For example, `yarn workspace spruce run storybook`.

### Testing

To run all unit tests across the repository, from root:
```bash
yarn test
```

To run a particular workspace's unit tests from root:
```bash
yarn test --selectProjects [workspace-name]
```
2 changes: 0 additions & 2 deletions apps/parsley/.graphqlrc

This file was deleted.

4 changes: 0 additions & 4 deletions apps/parsley/.husky/pre-commit

This file was deleted.

File renamed without changes.
1 change: 1 addition & 0 deletions apps/parsley/config/jest/setupTests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import "@testing-library/jest-dom/extend-expect";
// The following two variables are dummy values used in auth.test.tsx.
process.env.REACT_APP_EVERGREEN_URL = "test-evergreen.com";
process.env.REACT_APP_GRAPHQL_URL = "test-graphql.com";
process.env.REACT_APP_SPRUCE_URL = "test-spruce.com";

if (process.env.CI) {
// Avoid printing debug statements when running tests.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
describe("Basic resmoke log view", () => {
const logLink =
"/resmoke/mongodb_mongo_master_enterprise_amazon_linux2_arm64_all_feature_flags_jsCore_patch_9801cf147ed208ce4c0ff8dff4a97cdb216f4c22_65f06bd09ccd4eaaccca1391_24_03_12_14_51_29/0/job0/all";
beforeEach(() => {
cy.visit(logLink);
});

it("should render resmoke lines", () => {
cy.dataCy("resmoke-row").should("be.visible");
cy.dataCy("ansii-row").should("not.exist");
});

it("the HTML log button is disabled", () => {
cy.toggleDetailsPanel(true);
cy.dataCy("html-log-button").should("have.attr", "aria-disabled", "true");
});

it("the job logs button has a link to the job logs page", () => {
cy.toggleDetailsPanel(true);
cy.dataCy("job-logs-button").should(
"have.attr",
"href",
"http://localhost:3000/job-logs/mongodb_mongo_master_enterprise_amazon_linux2_arm64_all_feature_flags_jsCore_patch_9801cf147ed208ce4c0ff8dff4a97cdb216f4c22_65f06bd09ccd4eaaccca1391_24_03_12_14_51_29/0/job0",
);
});

it("should show the project, patch, task, and group the breadcrumb", () => {
cy.dataCy("project-breadcrumb")
.contains("mongodb-mongo-master")
.should("be.visible");
cy.dataCy("version-breadcrumb").contains("Patch 1994").should("be.visible");
cy.dataCy("task-breadcrumb").contains("jsCore").should("be.visible");
cy.dataCy("group-breadcrumb").contains("job0").should("be.visible");
});
});
Loading

0 comments on commit 801694d

Please sign in to comment.