Skip to content

Unit tests for the settings channel #146

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

Merged

Conversation

bwikbs
Copy link
Member

@bwikbs bwikbs commented Jul 15, 2021

  • TC is taken from the window port
  • Divide the setting channel into two part (common / platform)
  • Change the interface of setting channel

@bwikbs bwikbs force-pushed the unittest_settingchannel branch from 5e7891d to fee84ca Compare July 15, 2021 22:22
@bwikbs bwikbs marked this pull request as ready for review July 15, 2021 23:01
@bwikbs bwikbs force-pushed the unittest_settingchannel branch from b81ebfd to fd3997d Compare July 16, 2021 01:03
bwikbs added 2 commits July 19, 2021 07:39
* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>
Signed-off-by: MuHong Byun <[email protected]>
Copy link

@bbrto21 bbrto21 left a comment

Choose a reason for hiding this comment

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

LGTM!

@swift-kim swift-kim changed the title Unit test for setting channel Unit tests for the settings channel Jul 19, 2021
@bwikbs bwikbs force-pushed the unittest_settingchannel branch from d28dac6 to 97ac287 Compare July 19, 2021 05:11
Comment on lines 5 to 9
#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"
#include "flutter_tizen_engine.h"
#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"

Signed-off-by: MuHong Byun <[email protected]>
@bwikbs bwikbs force-pushed the unittest_settingchannel branch from 97ac287 to 22c726c Compare July 19, 2021 05:29
Comment on lines +7 to +8
#include <chrono>
#include <ctime>
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
#include <chrono>
#include <ctime>
#include <locale>

Comment on lines +5 to +6
#include <system/system_settings.h>
#include "settings_channel.h"
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
#include <system/system_settings.h>
#include "settings_channel.h"
#include "settings_channel.h"
#include <system/system_settings.h>

@bbrto21 bbrto21 merged commit a98a85c into flutter-tizen:flutter-2.2.1-tizen Jul 19, 2021
@swift-kim
Copy link
Member

@bbrto21 😕😕😕

@bwikbs
Copy link
Member Author

bwikbs commented Jul 19, 2021

@bbrto21 confusedconfusedconfused

😢

@bwikbs
Copy link
Member Author

bwikbs commented Jul 19, 2021

flutter_tizen_engine_unittest.cc

#include <gtest/gtest.h>

#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"

#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"

flutter_tizen_texture_registrar_unittests.cc

#include <gtest/gtest.h>
#include <iostream>

#include "flutter/shell/platform/tizen/flutter_tizen_texture_registrar.h"

#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"

settings_channel_tizen.cc

#include "settings_channel.h"

#include <system/system_settings.h>

@swift-kim @bbrto21 How about this?

@bwikbs
Copy link
Member Author

bwikbs commented Jul 19, 2021

This is final version!
flutter_tizen_engine_unittest.cc

#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"

#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"
#include "gtest/gtest.h"

flutter_tizen_texture_registrar_unittests.cc

#include "flutter/shell/platform/tizen/flutter_tizen_texture_registrar.h"

#include <iostream>

#include "flutter/shell/platform/embedder/test_utils/proc_table_replacement.h"
#include "flutter/shell/platform/tizen/flutter_tizen_engine.h"
#include "flutter/shell/platform/tizen/testing/engine_modifier.h"
#include "gtest/gtest.h"

settings_channel_tizen.cc

#include "settings_channel.h"

#include <system/system_settings.h>

@bbrto21
Copy link

bbrto21 commented Jul 19, 2021

@swift-kim Sorry! I just saw approval and missed the conversation.

@swift-kim
Copy link
Member

@bwikbs I applied it in #147. Thanks!

@bbrto21 No problem :D

engine_->RunEngine();

EXPECT_TRUE(run_called);
EXPECT_TRUE(update_locales_called);
Copy link

Choose a reason for hiding this comment

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

Currently, this test does not pass.

Copy link
Member Author

Choose a reason for hiding this comment

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

It will pass at #147. For the next PR, only TC was added intentionally.

swift-kim pushed a commit that referenced this pull request Sep 27, 2021
* Add setting channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Add localization_channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Revert "Add localization_channel unit test"

This reverts commit fd3997d.

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>

* Add review's commit

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Nov 14, 2021
* Add setting channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Add localization_channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Revert "Add localization_channel unit test"

This reverts commit fd3997d.

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>

* Add review's commit

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Dec 9, 2021
* Add setting channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Add localization_channel unit test

Signed-off-by: MuHong Byun <[email protected]>

* Revert "Add localization_channel unit test"

This reverts commit fd3997d.

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>

* Add review's commit

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Dec 17, 2021
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Feb 7, 2022
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Feb 11, 2022
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request May 12, 2022
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

* Apply review's comment

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Aug 5, 2022
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>
swift-kim pushed a commit that referenced this pull request Sep 1, 2022
* Dries up GN rules for Metal and OpenGL ES shader compilation and embedding in
  a target binary.
* Adds support for shader compile time macro definitions. This is so that
  workarounds for specific shader backends can be implemented. In the case of
  this patch, there are temporary OpenGLES workaround for users of instancing
  and SSBOs. These will be removed when I rework glyph rendering to not use
  these features that are missing in legacy targets.
* Since there is no concept of an OpenGLES shader library akin to a `.metallib`,
  adds a target called `blobcat` that concatenates shader blobs into single blob
  that can be embedded into a target binary. No parsing or data copying is
  necessary.
* `imgui_raster.vert` has been rewritten to work around the absence of unsigned
  integer types in legacy backends.
swift-kim pushed a commit that referenced this pull request Sep 1, 2022
* Add setting channel unit test

* Update minor things:

* Update flutter_tizen_engine_unittest (localization)
* Rename file :
  settings_channel_device.cc -> settings_channel_tizen.cc
  settings_channel_stub.cc -> settings_channel_linux.cc

Signed-off-by: MuHong Byun <[email protected]>
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.

3 participants