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

BDatetimepicker warns missing BInput #23

Closed
kikuomax opened this issue Aug 7, 2023 · 1 comment · Fixed by #251
Closed

BDatetimepicker warns missing BInput #23

kikuomax opened this issue Aug 7, 2023 · 1 comment · Fixed by #251
Assignees
Labels
good first issue Good for newcomers
Milestone

Comments

@kikuomax
Copy link
Collaborator

kikuomax commented Aug 7, 2023

Overview of the problem

Buefy version: buefy-next (67ecf3a)
Vuejs version: 3.3.4
OS/Browser: macOS/@vue/test-utils

Description

<b-datetimepicker> warns missing <b-input>.

[Vue warn]: Failed to resolve component: b-input

Steps to reproduce

I encountered this while working on unit tests of Datetimepicker:

In the packages/buefy-next folder, run the following command and see the warning messages are shown:

npx jest src/components/datetimepicker/Datetimepicker.spec.js

I have not confirmed on a browser but I think we could reproduce this if we specifically import Datetimepicker without installing the entire Buefy as a plugin.

Expected behavior

No warning is shown.

Actual behavior

The warning is shown.

kikuomax added a commit that referenced this issue Aug 7, 2023
- Updates the unit tests (spec) of `Datetimepicker` so that they can
  work with Vue 3 and `@vue/test-utils` V2:
    - Corrects v-model bindings:
        - property: `value` → `modelValue`
        - event: `input` → `update:modelValue`
    - Sets the locale "en-US" to produce predictable outputs. Replaces
      the expected outputs because I was not able to reproduce the old
      values:
        - "2019-10-1 08:30" → "10/1/2019, 8:30 AM"
    - Replaces `wrapper.find` with `findComponent` because `find` is
      dedicated to DOM elements on `@vue/test-utils` V2.
    - Awaits `wrapper.setProps` to make sure the subsequent tests verify
      the updated state.
    - Replaces `wrapper.name()` with `wrapper.vm.$options.name` because
      `wrapper.name` no longer exists in `@vue/test-utils` V2.
    - Replaces the test on `wrapper.isVueInstance()` with presence of
      `wrapper.vm` because `wrapper.isVueInstance` no longer exists in
      `@vue/test-utils` V2.
    - Replaces `propsData` option for `shallowMount` or `mount` with
      `props` because `propsData` might be deprecated in the future.
    - Makes `transition` a stub because whether `transition` is a stub
      or not does not matter to the test results.
    - Removes `sync` option for `mount`, because it has no effect and is
      unnecessary on `@vue/test-utils` V2.
    - We see warnings until we fix the issue #23

issue #1
kikuomax added a commit to kikuomax/buefy that referenced this issue Sep 4, 2023
- Updates the unit tests (spec) of `Datetimepicker` so that they can
  work with Vue 3 and `@vue/test-utils` V2:
    - Corrects v-model bindings:
        - property: `value` → `modelValue`
        - event: `input` → `update:modelValue`
    - Sets the locale "en-US" to produce predictable outputs. Replaces
      the expected outputs because I was not able to reproduce the old
      values:
        - "2019-10-1 08:30" → "10/1/2019, 8:30 AM"
    - Replaces `wrapper.find` with `findComponent` because `find` is
      dedicated to DOM elements on `@vue/test-utils` V2.
    - Awaits `wrapper.setProps` to make sure the subsequent tests verify
      the updated state.
    - Replaces `wrapper.name()` with `wrapper.vm.$options.name` because
      `wrapper.name` no longer exists in `@vue/test-utils` V2.
    - Replaces the test on `wrapper.isVueInstance()` with presence of
      `wrapper.vm` because `wrapper.isVueInstance` no longer exists in
      `@vue/test-utils` V2.
    - Replaces `propsData` option for `shallowMount` or `mount` with
      `props` because `propsData` might be deprecated in the future.
    - Makes `transition` a stub because whether `transition` is a stub
      or not does not matter to the test results.
    - Removes `sync` option for `mount`, because it has no effect and is
      unnecessary on `@vue/test-utils` V2.
    - We see warnings until we fix the issue ntohq#23

issue ntohq#1
wesdevpro pushed a commit that referenced this issue Sep 16, 2023
- Updates the unit tests (spec) of `Datetimepicker` so that they can
  work with Vue 3 and `@vue/test-utils` V2:
    - Corrects v-model bindings:
        - property: `value` → `modelValue`
        - event: `input` → `update:modelValue`
    - Sets the locale "en-US" to produce predictable outputs. Replaces
      the expected outputs because I was not able to reproduce the old
      values:
        - "2019-10-1 08:30" → "10/1/2019, 8:30 AM"
    - Replaces `wrapper.find` with `findComponent` because `find` is
      dedicated to DOM elements on `@vue/test-utils` V2.
    - Awaits `wrapper.setProps` to make sure the subsequent tests verify
      the updated state.
    - Replaces `wrapper.name()` with `wrapper.vm.$options.name` because
      `wrapper.name` no longer exists in `@vue/test-utils` V2.
    - Replaces the test on `wrapper.isVueInstance()` with presence of
      `wrapper.vm` because `wrapper.isVueInstance` no longer exists in
      `@vue/test-utils` V2.
    - Replaces `propsData` option for `shallowMount` or `mount` with
      `props` because `propsData` might be deprecated in the future.
    - Makes `transition` a stub because whether `transition` is a stub
      or not does not matter to the test results.
    - Removes `sync` option for `mount`, because it has no effect and is
      unnecessary on `@vue/test-utils` V2.
    - We see warnings until we fix the issue #23

issue #1
@kikuomax kikuomax added the good first issue Good for newcomers label Jan 10, 2024
@kikuomax kikuomax added this to the v0.1.4 milestone Apr 15, 2024
@wesdevpro wesdevpro added the need investigation Need investigation label Apr 29, 2024
@kikuomax
Copy link
Collaborator Author

kikuomax commented May 6, 2024

I have updated Section "Steps to reproduce".

wesdevpro added a commit that referenced this issue Jun 21, 2024
Fixes #23

- Adds import statement to include the missing input component
@wesdevpro wesdevpro self-assigned this Jun 21, 2024
@wesdevpro wesdevpro removed the need investigation Need investigation label Jun 21, 2024
kikuomax added a commit that referenced this issue Jul 14, 2024
I rewrite the CHANGELOG according to my preference, however we should
discuss and establish a minimum guideline for the CHANGELOG.

Categorizes the issue #19 as a "Breaking changes".

Removes "Fix" prefixes in the "Fixes" section because they look
redundant. Writes the issues instead of the solutions in the headlines.

Moves the issue #178 to a new category "Fixes (docs)"
because it does not matter to the core buefy-next library.

Adds the following fixes:
- #23
- #257
- #171 (docs)
wesdevpro pushed a commit that referenced this issue Jul 15, 2024
I rewrite the CHANGELOG according to my preference, however we should
discuss and establish a minimum guideline for the CHANGELOG.

Categorizes the issue #19 as a "Breaking changes".

Removes "Fix" prefixes in the "Fixes" section because they look
redundant. Writes the issues instead of the solutions in the headlines.

Moves the issue #178 to a new category "Fixes (docs)"
because it does not matter to the core buefy-next library.

Adds the following fixes:
- #23
- #257
- #171 (docs)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
Status: 👀 In review
Development

Successfully merging a pull request may close this issue.

2 participants