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

Feat: add platforms to hardware column #859

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

murilx
Copy link
Contributor

@murilx murilx commented Jan 29, 2025

  • Added hardware column to boots table
  • Added environment_misc.platform as a fallback to hardware when environment_compatible is full

Closes #854

Important: In the current form boots table is showing the hardware column in the hardware details page but tests table is not. Should hardware column be added to the tests table, should it be removed from the boots table or should I keep it like it is already?

@murilx murilx self-assigned this Jan 30, 2025
@murilx murilx force-pushed the feat/add-platforms-to-hardware-column branch 2 times, most recently from 8e11ebb to d59981a Compare January 30, 2025 14:31
Added enviroment_misc.platform as a fallback case for the hardware
column. When environment_compatible is null/undefined it will use the
platform of the test if available

Part of #854
    Added enviroment_misc.platform as a fallback case for the hardware
    column. When environment_compatible is null/undefined it will use the
    platform of the test if available

    Closes #854
@murilx murilx force-pushed the feat/add-platforms-to-hardware-column branch from d59981a to 589e34d Compare January 30, 2025 14:39
Comment on lines +9 to +11
: misc?.platform
? [misc?.platform]
: undefined;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is pretty much the same as misc?.platform

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

misc?.platform is type string | undefined and I need the result to be string[] | undefined. Doing only [misc?.platform], wouldn't work as well because that would be type (string | undefined)[]

];
import { buildHardwareArray } from '@/utils/table';

import { defaultColumns } from './DefaultBootsColumns';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there is pretty much no gain moving to another file it will be only used in a single place

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was following the same structure that was done to TestsTable but it makes sense, I'll change it back

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Show misc.platform in test table if hardware is undefined
3 participants